public abstract class AttributeValidator extends ContentValidator
ContentValidator.Nillability
childValidator, nil, pendingMessages
locallyInvalid
nextReceiver
pipelineConfiguration, previousAtomic, systemId
Constructor and Description |
---|
AttributeValidator(Receiver next)
Create an AttributeValidator
|
Modifier and Type | Method and Description |
---|---|
void |
attribute(NodeName attName,
SimpleType typeCode,
java.lang.CharSequence value,
Location location,
int properties)
Handle an attribute
|
void |
characters(java.lang.CharSequence chars,
Location locationId,
int properties)
Handle character data appearing as a child of the element being validated
|
SimpleType |
getMostRecentAttributeType()
Get the SimpleType used for validating the most recent attribute, if any
|
protected SchemaType |
processWildcardTerm(Wildcard card,
NodeName elementName,
Location locationId)
Process a wildcard term found in complex content or "all" content groups.
|
void |
setAttributeGroup(AttributeGroupDecl attributeGroup)
Identify the set of attributes permitted by the complex type being validated.
|
void |
startContent()
Notify the start of the content, that is, the completion of all attributes and namespaces.
|
void |
startElement(NodeName nameCode,
SchemaType typeCode,
Location location,
int properties)
Handle the start tag for a child element of the element being validated
|
checkNoCharactersWhenNil, checkNoChildrenWhenNil, endDocument, getAnnotation, getChildValidator, getContainingElement, getContainingElementLocationId, getContainingElementName, getElementDeclaration, getNamespaceResolver, getNillability, getSchemaType, isNil, makeChildValidator, makeValidator, makeValidatorForType, setAnnotation, setContainingElement, setElementDeclaration, setNillability
append, getConstraintChecker, getStartTagBuffer, getValidationContext, reportIfInvalid, reportValidationError, setConstraintChecker, setStartTagBuffer, setValidationContext, usesTypeAnnotations
close, comment, endElement, getNamePool, getNextReceiver, namespace, open, processingInstruction, setPipelineConfiguration, setSystemId, setUnderlyingReceiver, setUnparsedEntity, startDocument
append, decompose, flatten, getConfiguration, getErrorCodeForDecomposingFunctionItems, getPipelineConfiguration, getSystemId, handlesAppend
public AttributeValidator(Receiver next)
next
- the next receiver in the pipelinepublic void setAttributeGroup(AttributeGroupDecl attributeGroup) throws MissingComponentException
attributeGroup
- the set of attributes declared for this complex typeMissingComponentException
- if an unresolved reference is foundpublic void attribute(NodeName attName, SimpleType typeCode, java.lang.CharSequence value, Location location, int properties) throws XPathException
attribute
in interface Receiver
attribute
in class ProxyReceiver
attName
- integer identifying the name of the attributetypeCode
- integer identifying the type annotation (ignored)value
- the value of the attributelocation
- location of the originator of the attributeproperties
- additional properties of the attribute @throws net.sf.saxon.trans.XPathException
On any failure to write the attributeXPathException
- if an error occurspublic SimpleType getMostRecentAttributeType()
public void startElement(NodeName nameCode, SchemaType typeCode, Location location, int properties) throws XPathException
startElement
in interface Receiver
startElement
in class ContentValidator
nameCode
- integer code identifying the name of the element within the name pool.typeCode
- the element's type annotation.location
- a location associated with the event (typically either a location in the
source document or the stylesheet)properties
- properties of the element nodeXPathException
- if an error occurspublic final void startContent() throws XPathException
startContent
in interface Receiver
startContent
in class ProxyReceiver
XPathException
- if an error occurspublic void characters(java.lang.CharSequence chars, Location locationId, int properties) throws XPathException
characters
in interface Receiver
characters
in class ProxyReceiver
chars
- The character contentlocationId
- the location of the node in the source, or of the instruction that created itproperties
- Additional properties @throws net.sf.saxon.trans.XPathException
If this element does not allow character dataXPathException
- if an error occursprotected SchemaType processWildcardTerm(Wildcard card, NodeName elementName, Location locationId) throws XPathException
card
- the Wildcard that has been matchedelementName
- the name of the child elementlocationId
- the location of the child elementXPathException
- if the content is invalidCopyright (c) 2004-2020 Saxonica Limited. All rights reserved.