net.sf.saxon.s9api

Class XdmNodeKind

public class XdmNodeKind extends Enum<XdmNodeKind>

Enumeration class defining the seven kinds of node defined in the XDM model
Field Summary
static XdmNodeKindATTRIBUTE
static XdmNodeKindCOMMENT
static XdmNodeKindDOCUMENT
static XdmNodeKindELEMENT
static XdmNodeKindNAMESPACE
static XdmNodeKindPROCESSING_INSTRUCTION
static XdmNodeKindTEXT
static List<XdmNodeKind>VALUES
An immutable list containing the values comprising this enum class in the order they're declared.
Method Summary
List<XdmNodeKind>family()
Returns an immutable list containing the values comprising this enum class in the order they're declared.
protected intgetNumber()
static XdmNodeKindvalueOf(String name)
Static factory to return the enum constant pertaining to the given string name.

Field Detail

ATTRIBUTE

public static final XdmNodeKind ATTRIBUTE

COMMENT

public static final XdmNodeKind COMMENT

DOCUMENT

public static final XdmNodeKind DOCUMENT

ELEMENT

public static final XdmNodeKind ELEMENT

NAMESPACE

public static final XdmNodeKind NAMESPACE

PROCESSING_INSTRUCTION

public static final XdmNodeKind PROCESSING_INSTRUCTION

TEXT

public static final XdmNodeKind TEXT

VALUES

public static final List<XdmNodeKind> VALUES
An immutable list containing the values comprising this enum class in the order they're declared. This field may be used to iterate over the constants as follows:
for(XdmNodeKind c : XdmNodeKind.VALUES)
    System.out.println(c);

Method Detail

family

public final List<XdmNodeKind> family()
Returns an immutable list containing the values comprising this enum class in the order they're declared. This instance method simply returns VALUES. Few programmers should have any need to use this method. It is provided for use by sophisticated enum-based data structures to prevent the need for reflective access to VALUES.

Returns: an immutable list containing the values comprising this enum class, in the order they're declared.

getNumber

protected int getNumber()

valueOf

public static final XdmNodeKind valueOf(String name)
Static factory to return the enum constant pertaining to the given string name. The string must match exactly an identifier used to declare an enum constant in this type.

Throws: IllegalArgumentException if this enum class has no constant with the specified name.