public class IncludedXmlTag extends IncludedXmlElement<XmlTag> implements XmlTag
Iconable.IconFlags, Iconable.LastComputedIcon
myManager
FLAGS_LOCKED, ICON_PLACEHOLDER
EMPTY_ARRAY
EMPTY_ARRAY
DEPENDING_ELEMENT, DO_NOT_VALIDATE, INCLUDING_ELEMENT
ARRAY_FACTORY
ICON_FLAG_IGNORE_MASK, ICON_FLAG_OPEN, ICON_FLAG_READ_STATUS, ICON_FLAG_VISIBILITY
EMPTY_NAVIGATABLE_ELEMENT_ARRAY
EMPTY_NAVIGATION_ITEM_ARRAY
Constructor and Description |
---|
IncludedXmlTag(XmlTag original,
PsiElement parent) |
Modifier and Type | Method and Description |
---|---|
XmlTag |
addSubTag(XmlTag subTag,
boolean first) |
void |
collapseIfEmpty() |
XmlTag |
createChildTag(java.lang.String localName,
java.lang.String namespace,
java.lang.String bodyText,
boolean enforceNamespacesDeep)
Creates a new child tag
|
XmlTag |
findFirstSubTag(java.lang.String qname) |
XmlTag [] |
findSubTags(java.lang.String qname) |
XmlTag [] |
findSubTags(java.lang.String localName,
java.lang.String namespace) |
XmlAttribute |
getAttribute(java.lang.String qname)
Returns a tag attribute by qualified name.
|
XmlAttribute |
getAttribute(java.lang.String name,
java.lang.String namespace) |
XmlAttribute [] |
getAttributes() |
java.lang.String |
getAttributeValue(java.lang.String qname)
Returns a tag attribute value by qualified name.
|
java.lang.String |
getAttributeValue(java.lang.String name,
java.lang.String namespace) |
XmlElementDescriptor |
getDescriptor() |
java.lang.String |
getLocalName() |
java.util.Map<java.lang.String,java.lang.String> |
getLocalNamespaceDeclarations() |
PsiMetaData |
getMetaData() |
java.lang.String |
getName()
Returns the name of the element.
|
java.lang.String |
getNamespace() |
java.lang.String |
getNamespaceByPrefix(java.lang.String prefix) |
java.lang.String |
getNamespacePrefix() |
XmlTagChild |
getNextSiblingInTag() |
XmlNSDescriptor |
getNSDescriptor(java.lang.String namespace,
boolean strict) |
XmlTag |
getParentTag() |
java.lang.String |
getPrefixByNamespace(java.lang.String namespace) |
XmlTagChild |
getPrevSiblingInTag() |
XmlTag [] |
getSubTags() |
java.lang.String |
getSubTagText(java.lang.String qname) |
XmlTagValue |
getValue() |
boolean |
hasNamespaceDeclarations() |
boolean |
isEmpty() |
java.lang.String[] |
knownNamespaces() |
XmlAttribute |
setAttribute(java.lang.String qname,
java.lang.String value) |
XmlAttribute |
setAttribute(java.lang.String name,
java.lang.String namespace,
java.lang.String value) |
PsiElement |
setName(java.lang.String name)
Renames the element.
|
equals, getContainingFile, getNavigationElement, getOriginal, getParent, hashCode, isValid, processElements, toString
accept, add, addAfter, addBefore, checkAdd, checkDelete, copy, delete, findElementAt, getChildren, getLanguage, getManager, getNextSibling, getNode, getPrevSibling, getStartOffsetInParent, getText, getTextLength, getTextOffset, getTextRange, isPhysical, isWritable, replace, setNavigationElement, textMatches, textMatches, textToCharArray
acceptChildren, addRange, addRangeAfter, addRangeBefore, canNavigate, canNavigateToSource, deleteChildRange, findChildByClass, findChildrenByClass, findNotNullChildByClass, findReferenceAt, getContext, getFirstChild, getLastChild, getOriginalElement, getPresentation, getProject, getReference, getReferences, getResolveScope, getUseScope, isEquivalentTo, navigate, notNullChild, processDeclarations, textContains
buildRowIcon, computeBaseIcon, createLayeredIcon, getAdjustedBaseIcon, getBaseIcon, getElementIcon, getIcon, iconWithVisibilityIfNeeded, isNativeFileType, isVisibilitySupported, overlayIcons, registerIconLayer, transformFlags
changeUserMap, clearUserData, clone, copyCopyableDataTo, copyUserDataTo, getCopyableUserData, getUserData, getUserDataString, getUserMap, isUserDataEmpty, putCopyableUserData, putUserData, putUserDataIfAbsent, replace, setUserMap
finalize, getClass, notify, notifyAll, wait, wait, wait
getHostName, getRealNs, isCaseSensitive
processElements, skipValidation
accept, acceptChildren, add, addAfter, addBefore, addRange, addRangeAfter, addRangeBefore, checkAdd, checkDelete, copy, delete, deleteChildRange, findElementAt, findReferenceAt, getChildren, getContainingFile, getContext, getCopyableUserData, getFirstChild, getLanguage, getLastChild, getManager, getNavigationElement, getNextSibling, getNode, getOriginalElement, getOwnReferences, getParent, getPrevSibling, getProject, getReference, getReferences, getResolveScope, getStartOffsetInParent, getText, getTextLength, getTextOffset, getTextRange, getTextRangeInParent, getUseScope, isEquivalentTo, isPhysical, isValid, isWritable, processDeclarations, putCopyableUserData, replace, textContains, textMatches, textMatches, textToCharArray, toString
getUserData, putUserData
public IncludedXmlTag(XmlTag original, PsiElement parent)
public XmlTag getParentTag()
getParentTag
in interface XmlTagChild
public java.lang.String getName()
PsiNamedElement
getName
in interface NavigationItem
getName
in interface PsiNamedElement
getName
in interface XmlTag
getName
in class PsiElementBase
public PsiElement setName(java.lang.String name) throws IncorrectOperationException
PsiNamedElement
setName
in interface PsiNamedElement
name
- the new element name.this
or a different element if the rename caused the element to be replaced).IncorrectOperationException
- if the modification is not supported or not possible for some reason.public java.lang.String getNamespace()
getNamespace
in interface XmlTag
public java.lang.String getLocalName()
getLocalName
in interface XmlTag
public XmlElementDescriptor getDescriptor()
getDescriptor
in interface XmlTag
public XmlAttribute [] getAttributes()
getAttributes
in interface XmlTag
public XmlAttribute getAttribute(java.lang.String name, java.lang.String namespace)
getAttribute
in interface XmlTag
public XmlAttribute getAttribute(java.lang.String qname)
XmlTag
getAttribute
in interface XmlTag
qname
- qualified attribute name, like "ns:name" or "name".XmlTag.getAttribute(String, String)
public java.lang.String getAttributeValue(java.lang.String name, java.lang.String namespace)
getAttributeValue
in interface XmlTag
public java.lang.String getAttributeValue(java.lang.String qname)
XmlTag
getAttributeValue
in interface XmlTag
qname
- qualified attribute name, like "ns:name" or "name".XmlTag.getAttributeValue(String, String)
public XmlAttribute setAttribute(java.lang.String name, java.lang.String namespace, java.lang.String value) throws IncorrectOperationException
setAttribute
in interface XmlTag
IncorrectOperationException
public XmlAttribute setAttribute(java.lang.String qname, java.lang.String value) throws IncorrectOperationException
setAttribute
in interface XmlTag
IncorrectOperationException
public XmlTag createChildTag(java.lang.String localName, java.lang.String namespace, java.lang.String bodyText, boolean enforceNamespacesDeep)
XmlTag
createChildTag
in interface XmlTag
localName
- new tag's namenamespace
- new tag's namespacebodyText
- pass null to create collapsed tag, empty string means creating expanded oneenforceNamespacesDeep
- if you pass some xml tags to bodyText
parameter, this flag sets namespace prefixes for themXmlTag.addSubTag(XmlTag, boolean)
} to add it to parentpublic XmlTag [] getSubTags()
getSubTags
in interface XmlTag
public XmlTag [] findSubTags(java.lang.String qname)
findSubTags
in interface XmlTag
public XmlTag [] findSubTags(java.lang.String localName, java.lang.String namespace)
findSubTags
in interface XmlTag
localName
- non-qualified tag name.namespace
- if null, name treated as qualified name to find.public XmlTag findFirstSubTag(java.lang.String qname)
findFirstSubTag
in interface XmlTag
public java.lang.String getNamespacePrefix()
getNamespacePrefix
in interface XmlTag
public java.lang.String getNamespaceByPrefix(java.lang.String prefix)
getNamespaceByPrefix
in interface XmlTag
public java.lang.String getPrefixByNamespace(java.lang.String namespace)
getPrefixByNamespace
in interface XmlTag
public java.lang.String[] knownNamespaces()
knownNamespaces
in interface XmlTag
public boolean hasNamespaceDeclarations()
hasNamespaceDeclarations
in interface XmlTag
public java.util.Map<java.lang.String,java.lang.String> getLocalNamespaceDeclarations()
getLocalNamespaceDeclarations
in interface XmlTag
public XmlTagValue getValue()
public XmlNSDescriptor getNSDescriptor(java.lang.String namespace, boolean strict)
getNSDescriptor
in interface XmlTag
public void collapseIfEmpty()
collapseIfEmpty
in interface XmlTag
public java.lang.String getSubTagText(java.lang.String qname)
getSubTagText
in interface XmlTag
public PsiMetaData getMetaData()
getMetaData
in interface PsiMetaOwner
public XmlTagChild getNextSiblingInTag()
getNextSiblingInTag
in interface XmlTagChild
public XmlTagChild getPrevSiblingInTag()
getPrevSiblingInTag
in interface XmlTagChild