net.sf.saxon.event
Class IDFilter
public
class
IDFilter
extends StartTagBuffer
IDFilter is a ProxyReceiver that extracts the subtree of a document rooted at the
element with a given ID value. Namespace declarations outside this subtree are
treated as if they were present on the identified element.
Method Summary |
void | attribute(int nameCode, int typeCode, CharSequence value, int locationId, int properties)
Notify an attribute. |
void | characters(CharSequence chars, int locationId, int properties)
Character data |
void | comment(CharSequence chars, int locationId, int properties)
Output a comment |
protected void | declareNamespacesForStartElement() |
void | endElement()
endElement: |
void | processingInstruction(String target, CharSequence data, int locationId, int properties)
Processing Instruction |
void | startContent()
startContent: Test if a matching ID attribute was found; if so, start outputting. |
void | startElement(int nameCode, int typeCode, int locationId, int properties)
startElement |
public IDFilter(String id)
public void attribute(int nameCode, int typeCode, CharSequence value, int locationId, int properties)
Notify an attribute. Attributes are notified after the startElement event, and before any
children. Namespaces and attributes may be intermingled.
Parameters: nameCode The name of the attribute, as held in the name pool typeCode The type of the attribute, as held in the name pool properties Bit significant value. The following bits are defined:
DISABLE_ESCAPING Disable escaping for this attribute
NO_SPECIAL_CHARACTERS Attribute value contains no special characters
Throws: IllegalStateException: attempt to output an attribute when there is no open element
start tag
public void characters(CharSequence chars, int locationId, int properties)
Character data
public void comment(CharSequence chars, int locationId, int properties)
Output a comment
protected void declareNamespacesForStartElement()
public void endElement()
endElement:
public void processingInstruction(String target, CharSequence data, int locationId, int properties)
Processing Instruction
public void startContent()
startContent: Test if a matching ID attribute was found; if so, start outputting.
public void startElement(int nameCode, int typeCode, int locationId, int properties)
startElement