com.jclark.xsl.om
Interface Node

All Superinterfaces:
javax.xml.transform.SourceLocator
All Known Implementing Classes:
AttributeNode, CommentNode, ContainerNode, ElementNode, NodeBase, ProcessingInstructionNode, RootNode, TextNode

public interface Node
extends javax.xml.transform.SourceLocator

represents a Node in an XML document


Field Summary
static byte ALLTYPES
           
static byte ATTRIBUTE
           
static byte COMMENT
           
static byte ELEMENT
           
static int N_TYPES
           
static byte NAMESPACE
           
static byte PROCESSING_INSTRUCTION
           
static byte ROOT
           
static byte TEXT
           
 
Method Summary
 int compareTo(Node node)
          also compares document order
 Node getAttribute(Name name)
          does this only work on Elements?
 SafeNodeIterator getAttributes()
          does this only work on Elements?
 java.lang.String getAttributeValue(Name name)
          does this only work on Elements?
 SafeNodeIterator getChildren()
          as the name implies ...
 java.lang.String getData()
          Returns text for TEXT node; value for attribute node; content for comment node; content after PI for PI node;
 Node getElementWithId(java.lang.String id)
          finds an Element Node, in the this node's document, with the given ID
 SafeNodeIterator getFollowingSiblings()
          as the name implies ...
 java.lang.String getGeneratedId()
          guaranteed to be unique (and repeatable)
 int getLineNumber()
          if decorated with locator events, this returns the line number in the XML source where this node was found
 Name getName()
          Returns element type name for element; attribute name for an attribute; target for a PI., Namespace prefix for a Namespace
 NamespacePrefixMap getNamespacePrefixMap()
          in-scope namespaces ??
 SafeNodeIterator getNamespaces()
          does this only work on Elements?
 Node getParent()
          as the name implies ...
 Node getRoot()
          gets the owning Document's root
 byte getType()
          returns one of: ELEMENT, TEXT, ATTRIBUTE, ROOT, PROCESSING_INSTRUCTION or COMMENT
 java.lang.String getUnparsedEntityURI(java.lang.String name)
           
 java.net.URL getURL()
          base URL ??
 boolean isId(java.lang.String id)
          if this is an attribute?? and it is of type ID ?
 
Methods inherited from interface javax.xml.transform.SourceLocator
getColumnNumber, getPublicId, getSystemId
 

Field Detail

ELEMENT

static final byte ELEMENT
See Also:
Constant Field Values

TEXT

static final byte TEXT
See Also:
Constant Field Values

ATTRIBUTE

static final byte ATTRIBUTE
See Also:
Constant Field Values

ROOT

static final byte ROOT
See Also:
Constant Field Values

PROCESSING_INSTRUCTION

static final byte PROCESSING_INSTRUCTION
See Also:
Constant Field Values

COMMENT

static final byte COMMENT
See Also:
Constant Field Values

NAMESPACE

static final byte NAMESPACE
See Also:
Constant Field Values

N_TYPES

static final int N_TYPES
See Also:
Constant Field Values

ALLTYPES

static final byte ALLTYPES
See Also:
Constant Field Values
Method Detail

getType

byte getType()
returns one of: ELEMENT, TEXT, ATTRIBUTE, ROOT, PROCESSING_INSTRUCTION or COMMENT


getName

Name getName()
Returns element type name for element; attribute name for an attribute; target for a PI., Namespace prefix for a Namespace


getData

java.lang.String getData()
Returns text for TEXT node; value for attribute node; content for comment node; content after PI for PI node;


getParent

Node getParent()
as the name implies ...


getChildren

SafeNodeIterator getChildren()
as the name implies ...


getFollowingSiblings

SafeNodeIterator getFollowingSiblings()
as the name implies ...


getURL

java.net.URL getURL()
base URL ??


getLineNumber

int getLineNumber()
if decorated with locator events, this returns the line number in the XML source where this node was found

Specified by:
getLineNumber in interface javax.xml.transform.SourceLocator

getNamespacePrefixMap

NamespacePrefixMap getNamespacePrefixMap()
in-scope namespaces ??


compareTo

int compareTo(Node node)
also compares document order


getElementWithId

Node getElementWithId(java.lang.String id)
finds an Element Node, in the this node's document, with the given ID


isId

boolean isId(java.lang.String id)
if this is an attribute?? and it is of type ID ?


getAttributeValue

java.lang.String getAttributeValue(Name name)
does this only work on Elements?


getAttribute

Node getAttribute(Name name)
does this only work on Elements?


getAttributes

SafeNodeIterator getAttributes()
does this only work on Elements?


getNamespaces

SafeNodeIterator getNamespaces()
does this only work on Elements?


getGeneratedId

java.lang.String getGeneratedId()
guaranteed to be unique (and repeatable)


getUnparsedEntityURI

java.lang.String getUnparsedEntityURI(java.lang.String name)

getRoot

Node getRoot()
gets the owning Document's root