use of com.intellij.psi.scope.processor.FilterElementProcessor in project intellij-community by JetBrains.
the class XmlEnumeratedTypeImpl method getEnumeratedValues.
@Override
public XmlElement[] getEnumeratedValues() {
final List<XmlElement> result = new ArrayList<>();
processElements(new FilterElementProcessor(new XmlTokenTypeFilter(XmlTokenType.XML_NAME), result), this);
return result.toArray(new XmlElement[result.size()]);
}
use of com.intellij.psi.scope.processor.FilterElementProcessor in project intellij-community by JetBrains.
the class XmlAttlistDeclImpl method getAttributeDecls.
@Override
public XmlAttributeDecl[] getAttributeDecls() {
final List<XmlAttributeDecl> result = new ArrayList<>();
processElements(new FilterElementProcessor(new ClassFilter(XmlAttributeDecl.class), result) {
@Override
public boolean execute(@NotNull final PsiElement element) {
if (element instanceof XmlAttributeDecl) {
if (element.getNextSibling() == null && element.getChildren().length == 1) {
return true;
}
return super.execute(element);
}
return true;
}
}, this);
return result.toArray(new XmlAttributeDecl[result.size()]);
}
Aggregations