Package com.helger.xml.dom
Enum EXMLDOMNodeType
- java.lang.Object
-
- java.lang.Enum<EXMLDOMNodeType>
-
- com.helger.xml.dom.EXMLDOMNodeType
-
- All Implemented Interfaces:
com.helger.commons.id.IHasIntID,Serializable,Comparable<EXMLDOMNodeType>
public enum EXMLDOMNodeType extends Enum<EXMLDOMNodeType> implements com.helger.commons.id.IHasIntID
Represents the different DOM node types. This is a type-safe version of the node types defined inNode.- Author:
- Philip Helger
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ATTRIBUTE_NODEThe node is anAttr.CDATA_SECTION_NODEThe node is aCDATASection.COMMENT_NODEThe node is aComment.DOCUMENT_FRAGMENT_NODEThe node is aDocumentFragment.DOCUMENT_NODEThe node is aDocument.DOCUMENT_TYPE_NODEThe node is aDocumentType.ELEMENT_NODEThe node is anElement.ENTITY_NODEThe node is anEntity.ENTITY_REFERENCE_NODEThe node is anEntityReference.NOTATION_NODEThe node is aNotation.PROCESSING_INSTRUCTION_NODEThe node is aProcessingInstruction.TEXT_NODEThe node is aTextnode.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static EXMLDOMNodeTypegetFromIDOrNull(int nID)intgetID()static EXMLDOMNodeTypevalueOf(String name)Returns the enum constant of this type with the specified name.static EXMLDOMNodeType[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
ELEMENT_NODE
public static final EXMLDOMNodeType ELEMENT_NODE
The node is anElement.
-
ATTRIBUTE_NODE
public static final EXMLDOMNodeType ATTRIBUTE_NODE
The node is anAttr.
-
TEXT_NODE
public static final EXMLDOMNodeType TEXT_NODE
The node is aTextnode.
-
CDATA_SECTION_NODE
public static final EXMLDOMNodeType CDATA_SECTION_NODE
The node is aCDATASection.
-
ENTITY_REFERENCE_NODE
public static final EXMLDOMNodeType ENTITY_REFERENCE_NODE
The node is anEntityReference.
-
ENTITY_NODE
public static final EXMLDOMNodeType ENTITY_NODE
The node is anEntity.
-
PROCESSING_INSTRUCTION_NODE
public static final EXMLDOMNodeType PROCESSING_INSTRUCTION_NODE
The node is aProcessingInstruction.
-
COMMENT_NODE
public static final EXMLDOMNodeType COMMENT_NODE
The node is aComment.
-
DOCUMENT_NODE
public static final EXMLDOMNodeType DOCUMENT_NODE
The node is aDocument.
-
DOCUMENT_TYPE_NODE
public static final EXMLDOMNodeType DOCUMENT_TYPE_NODE
The node is aDocumentType.
-
DOCUMENT_FRAGMENT_NODE
public static final EXMLDOMNodeType DOCUMENT_FRAGMENT_NODE
The node is aDocumentFragment.
-
NOTATION_NODE
public static final EXMLDOMNodeType NOTATION_NODE
The node is aNotation.
-
-
Method Detail
-
values
public static EXMLDOMNodeType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (EXMLDOMNodeType c : EXMLDOMNodeType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static EXMLDOMNodeType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
getID
@Nonnegative public int getID()
- Specified by:
getIDin interfacecom.helger.commons.id.IHasIntID
-
getFromIDOrNull
@Nullable public static EXMLDOMNodeType getFromIDOrNull(int nID)
-
-