public class IdValidator extends ProxyReceiver
nextReceiverpipelineConfiguration, previousAtomic, systemIdPI_DISABLE_OUTPUT_ESCAPING, PI_ENABLE_OUTPUT_ESCAPING| Constructor and Description |
|---|
IdValidator(Receiver next)
Create a validator for ID/IDREF constraints
|
| Modifier and Type | Method and Description |
|---|---|
void |
attribute(NodeName nameCode,
SimpleType type,
CharSequence value,
int locationId,
int properties)
Handle an attribute
|
void |
characters(CharSequence chars,
int locationId,
int properties)
Character data
|
void |
close()
End of document
|
void |
endElement()
End of element
|
protected void |
reportValidationError(ValidationException err,
long locationId)
Report a validation error
|
void |
setConstraintChecker(ConstraintChecker checker)
Set the owning ConstraintChecker
|
void |
startElement(NodeName nameCode,
SchemaType typeCode,
int locationId,
int properties)
Notify the start of an element
|
boolean |
usesTypeAnnotations()
Ask whether this Receiver (or the downstream pipeline) makes any use of the type annotations
supplied on element and attribute events
|
append, comment, endDocument, getNamePool, getUnderlyingReceiver, namespace, open, processingInstruction, setPipelineConfiguration, setSystemId, setUnderlyingReceiver, setUnparsedEntity, startContent, startDocumentappend, getConfiguration, getPipelineConfiguration, getSystemIdpublic IdValidator(Receiver next)
next - the next receiver in the pipelinepublic void setConstraintChecker(ConstraintChecker checker)
checker - the owning ConstraintCheckerpublic void startElement(NodeName nameCode, SchemaType typeCode, int locationId, int properties) throws XPathException
startElement in interface ReceiverstartElement in class ProxyReceivernameCode - integer code identifying the name of the element within the name pool.typeCode - integer code identifying the element's type within the name pool.properties - for future use. Should be set to zero.locationId - an integer which can be interpreted using a LocationProvider to return
information such as line number and system ID. If no location information is available,
the value zero is supplied.XPathException - if an error occurspublic void characters(CharSequence chars, int locationId, int properties) throws XPathException
characters in interface Receivercharacters in class ProxyReceiverchars - The characterslocationId - an integer which can be interpreted using a LocationProvider
to return information such as line number and system ID. If no location information is available,
the value zero is supplied.properties - Bit significant value. The following bits are defined:
XPathException - if an error occurspublic void endElement()
throws XPathException
endElement in interface ReceiverendElement in class ProxyReceiverXPathException - if an error occurspublic void attribute(NodeName nameCode, SimpleType type, CharSequence value, int locationId, int properties) throws XPathException
attribute in interface Receiverattribute in class ProxyReceivernameCode - integer identifying the name of the attributetype - the type annotationvalue - the value of the attributeproperties - additional properties of the attributelocationId - an integer which can be interpreted using a LocationProvider to return
information such as line number and system ID. If no location information is available,
the value zero is supplied.XPathException - On any failure to write the attributepublic void close()
throws XPathException
close in interface Receiverclose in class ProxyReceiverXPathException - if an error occurspublic boolean usesTypeAnnotations()
usesTypeAnnotations in interface ReceiverusesTypeAnnotations in class ProxyReceiverprotected void reportValidationError(ValidationException err, long locationId) throws ValidationException
err - The validation exceptionlocationId - identifies the location in the source document or stylesheet/query where the
validation error was detectedValidationException - if the error is determined to be fatalCopyright (c) 2004-2013 Saxonica Limited. All rights reserved.