本文整理汇总了Java中org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil类的典型用法代码示例。如果您正苦于以下问题:Java RenameUtil类的具体用法?Java RenameUtil怎么用?Java RenameUtil使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
RenameUtil类属于org.intellij.plugins.relaxNG.compact.psi.util包,在下文中一共展示了RenameUtil类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: handleElementRename
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
@Override
public PsiElement handleElementRename(String newElementName) throws IncorrectOperationException {
final ASTNode node = getNode();
final ASTNode child = RenameUtil.createPrefixedNode(getManager(), newElementName, getLocalPart());
node.getTreeParent().replaceChild(node, child);
return child.getPsi();
}
示例2: handleElementRename
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
@Override
public PsiElement handleElementRename(String newElementName) throws IncorrectOperationException {
final ASTNode newNode = RenameUtil.createIdentifierNode(getElement().getManager(), newElementName);
final ASTNode nameNode = findNameNode();
nameNode.getTreeParent().replaceChild(nameNode, newNode);
return getElement();
}
示例3: setName
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
@Override
public PsiElement setName(@NonNls @NotNull String name) throws IncorrectOperationException {
final ASTNode node = findIdentifierNode();
if (node == null) return this;
node.getTreeParent().replaceChild(node, RenameUtil.createIdentifierNode(getManager(), name));
return this;
}
示例4: handleElementRename
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
public PsiElement handleElementRename(String newElementName) throws IncorrectOperationException {
final ASTNode newNode = RenameUtil.createIdentifierNode(getElement().getManager(), newElementName);
final ASTNode nameNode = findNameNode();
nameNode.getTreeParent().replaceChild(nameNode, newNode);
return getElement();
}
示例5: isKeyword
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
@Override
public boolean isKeyword(@NotNull String name, Project project) {
return RenameUtil.isKeyword(name);
}
示例6: isIdentifier
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
@Override
public boolean isIdentifier(@NotNull String name, Project project) {
return RenameUtil.isIdentifier(name);
}
示例7: setName
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
@Override
public PsiElement setName(@NonNls @NotNull String name) throws IncorrectOperationException {
final ASTNode node = getNameNode();
node.getTreeParent().replaceChild(node, RenameUtil.createIdentifierNode(getManager(), name));
return this;
}
示例8: isKeyword
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
public boolean isKeyword(String name, Project project) {
return RenameUtil.isKeyword(name);
}
示例9: isIdentifier
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
public boolean isIdentifier(String name, Project project) {
return RenameUtil.isIdentifier(name);
}
示例10: setName
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
public PsiElement setName(@NonNls @NotNull String name) throws IncorrectOperationException {
final ASTNode node = getNameNode();
node.getTreeParent().replaceChild(node, RenameUtil.createIdentifierNode(getManager(), name));
return this;
}
示例11: handleElementRename
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
public PsiElement handleElementRename(String newElementName) throws IncorrectOperationException {
final ASTNode node = getNode();
final ASTNode child = RenameUtil.createPrefixedNode(getManager(), newElementName, getLocalPart());
node.getTreeParent().replaceChild(node, child);
return child.getPsi();
}
示例12: setName
import org.intellij.plugins.relaxNG.compact.psi.util.RenameUtil; //导入依赖的package包/类
public PsiElement setName(@NonNls @NotNull String name) throws IncorrectOperationException {
final ASTNode node = findIdentifierNode();
if (node == null) return this;
node.getTreeParent().replaceChild(node, RenameUtil.createIdentifierNode(getManager(), name));
return this;
}