public abstract class PsiElementPattern<T extends PsiElement,Self extends PsiElementPattern<T,Self>> extends TreeElementPattern<PsiElement,T,Self>
Modifier and Type | Class and Description |
---|---|
static class |
PsiElementPattern.Capture<T extends PsiElement> |
Modifier | Constructor and Description |
---|---|
protected |
PsiElementPattern(java.lang.Class<T> aClass) |
protected |
PsiElementPattern(InitialPatternCondition<T> condition) |
afterSibling, afterSiblingSkipping, inside, inside, inside, inside, insideSequence, isFirstAcceptedChild, withAncestor, withChild, withChildren, withFirstChild, withLastChild, withParent, withParent, withParents, withSuperParent, withSuperParent
protected PsiElementPattern(java.lang.Class<T> aClass)
protected PsiElementPattern(InitialPatternCondition<T> condition)
protected PsiElement[] getChildren(PsiElement element)
getChildren
in class TreeElementPattern<PsiElement,T extends PsiElement,Self extends PsiElementPattern<T,Self>>
protected PsiElement getParent(PsiElement element)
getParent
in class TreeElementPattern<PsiElement,T extends PsiElement,Self extends PsiElementPattern<T,Self>>
public Self withElementType(IElementType type)
public Self afterLeaf(java.lang.String... withText)
public Self afterLeaf(ElementPattern<? extends PsiElement> pattern)
public Self beforeLeaf(java.lang.String... withText)
public Self beforeLeaf(ElementPattern<? extends PsiElement> pattern)
public Self whitespace()
public Self whitespaceCommentOrError()
public Self whitespaceCommentEmptyOrError()
public Self withFirstNonWhitespaceChild(ElementPattern<? extends PsiElement> pattern)
public Self withReference(java.lang.Class<? extends PsiReference> referenceClass)
public Self inFile(ElementPattern<? extends PsiFile> filePattern)
public Self inVirtualFile(ElementPattern<? extends VirtualFile> filePattern)
public Self equalTo(T o)
equalTo
in class ObjectPattern<T extends PsiElement,Self extends PsiElementPattern<T,Self>>
public Self withElementType(ElementPattern<IElementType> pattern)
public Self withText(java.lang.String text)
public Self withoutText(java.lang.String text)
public Self withName(java.lang.String name)
public Self withName(java.lang.String... names)
public Self withName(ElementPattern<java.lang.String> name)
public Self afterLeafSkipping(ElementPattern skip, ElementPattern pattern)
public Self beforeLeafSkipping(ElementPattern skip, ElementPattern pattern)
public Self atStartOf(ElementPattern pattern)
public Self withTextLength(ElementPattern lengthPattern)
public Self notEmpty()
public Self withTextLengthLongerThan(int minLength)
public Self withText(ElementPattern text)
public Self withoutText(ElementPattern text)
public Self withMetaData(ElementPattern<? extends PsiMetaData> metaDataPattern)
public Self referencing(ElementPattern<? extends PsiElement> targetPattern)
public Self compiled()
public Self withTreeParent(ElementPattern<? extends PsiElement> ancestor)
public Self insideStarting(ElementPattern<? extends PsiElement> ancestor)
public Self withLastChildSkipping(ElementPattern skip, ElementPattern pattern)