XmlAttributeDescriptor[] (final XmlTag context) { final List<XmlAttributeDescriptor> result = new SmartList<>(); for (XmlAttlistDecl attlistDecl : findAttlistDeclarations(getName())) { for (XmlAttributeDecl attributeDecl : attlistDecl.getAttributeDecls()) { final PsiMetaData psiMetaData = attributeDecl.getMetaData(); assert psiMetaData instanceof XmlAttributeDescriptor; result.add((XmlAttributeDescriptor)psiMetaData); } } return result.toArray(XmlAttributeDescriptor.EMPTY); }