Package org.gjt.xpp
Interface XmlTag
-
- All Known Subinterfaces:
XmlEndTag,XmlNode,XmlPullNode,XmlStartTag
public interface XmlTagBase interface that encapsulates common functionality for XML elements: both start tag and end tag (an empty element is equivalent to start tag followed by end tag so for simplicity ti is not modeled as a separate class).- Author:
- Aleksander Slominski
- See Also:
XmlStartTag,XmlEndTag
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.StringgetLocalName()Returns the local name of the current elementjava.lang.StringgetNamespaceUri()Returns the namespace URI of the current element Returns null if not applicablejava.lang.StringgetPrefix()Returns the prefix of the current element or null if elemet has no prefix.java.lang.StringgetRawName()Returns the raw name (prefix + ':' + localName) of the current elementvoidmodifyTag(java.lang.String namespaceURI, java.lang.String localName, java.lang.String rawName)Modify tag to have namespace URI, localName and rawName.voidresetTag()Clear all Tag state to default values.
-
-
-
Method Detail
-
resetTag
void resetTag()
Clear all Tag state to default values.
-
getNamespaceUri
java.lang.String getNamespaceUri()
Returns the namespace URI of the current element Returns null if not applicable
-
getLocalName
java.lang.String getLocalName()
Returns the local name of the current element
-
getPrefix
java.lang.String getPrefix()
Returns the prefix of the current element or null if elemet has no prefix.
-
getRawName
java.lang.String getRawName()
Returns the raw name (prefix + ':' + localName) of the current element
-
modifyTag
void modifyTag(java.lang.String namespaceURI, java.lang.String localName, java.lang.String rawName) throws XmlPullParserExceptionModify tag to have namespace URI, localName and rawName.NOTE: setting modeled after SAX2 startTag
- Parameters:
namespaceURI- maybe null then default "" namespace is usedlocalName- may be null then rawName is usedrawName- actual attribute name MUST be not null if it is null exception MUST be thrown- Throws:
XmlPullParserException
-
-