public class ComplexContentValidator extends AttributeValidator
childValidator, nil, NIL_ALLOWED, NIL_DISALLOWED, NIL_IGNORED, pendingMessages
locallyInvalid
nextReceiver
pipelineConfiguration, previousAtomic, systemId
PI_DISABLE_OUTPUT_ESCAPING, PI_ENABLE_OUTPUT_ESCAPING
Constructor and Description |
---|
ComplexContentValidator(ElementDecl declaration,
UserComplexType type,
Receiver next)
Create a ComplexContentValidator for a given type
|
Modifier and Type | Method and Description |
---|---|
void |
characters(CharSequence chars,
int locationId,
int properties)
Handle character data appearing as a child of the element being validated
|
void |
endElement()
Validation at the end of the element being validated.
|
protected ContentValidator |
getChildValidator()
Get a validator to handle the children of the current element.
|
SchemaType |
getSchemaType()
Get the schema type against which we are validating, if any
|
void |
setPipelineConfiguration(PipelineConfiguration pipe)
Set the pipeline configuration
|
void |
setSchemaType(UserComplexType type)
Set the schema type against which this validator is to validate the instance element
|
void |
startElement(NodeName elemName,
SchemaType typeCode,
int locationId,
int properties)
Handle the start tag for a child element of the element being validated
|
attribute, getMostRecentAttributeType, noCharactersWhenNil, processWildcardTerm, setAttributeGroup, startContent
endDocument, getAnnotation, getContainingElement, getContainingElementLocationId, getContainingElementName, getElementDeclaration, getNamespaceResolver, getNillability, isNil, makeChildValidator, makeValidator, makeValidatorForType, setAnnotation, setContainingElement, setElementDeclaration, setNillability
append, getConstraintChecker, getStartTagBuffer, getValidationContext, reportIfInvalid, reportValidationError, setConstraintChecker, setStartTagBuffer, setValidationContext, usesTypeAnnotations
close, comment, getNamePool, getUnderlyingReceiver, namespace, open, processingInstruction, setSystemId, setUnderlyingReceiver, setUnparsedEntity, startDocument
append, getConfiguration, getPipelineConfiguration, getSystemId, isTrueSequenceReceiver
public ComplexContentValidator(ElementDecl declaration, UserComplexType type, Receiver next) throws ValidationException
declaration
- the element declaration, if available, or null otherwise.type
- the complex typenext
- the next receiver in the pipelineValidationException
- if the schema is incomplete or invalidpublic void setPipelineConfiguration(PipelineConfiguration pipe)
Receiver
setPipelineConfiguration
in interface Receiver
setPipelineConfiguration
in class ProxyReceiver
pipe
- the pipeline configurationpublic void setSchemaType(UserComplexType type) throws ValidationException
type
- the schema type used for validationValidationException
- if there is a problem with the schemapublic SchemaType getSchemaType()
ContentValidator
getSchemaType
in class ContentValidator
public void startElement(NodeName elemName, SchemaType typeCode, int locationId, int properties) throws XPathException
startElement
in interface Receiver
startElement
in class AttributeValidator
elemName
- integer code identifying the name of the element within the name pool.typeCode
- integer code identifying the element's type within the name pool.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.properties
- properties of the element nodeXPathException
- if an error occursprotected ContentValidator getChildValidator()
getChildValidator
in class ContentValidator
public void characters(CharSequence chars, int locationId, int properties) throws XPathException
characters
in interface Receiver
characters
in class AttributeValidator
chars
- The character contentproperties
- Additional propertieslocationId
- 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 this element does not allow character datapublic void endElement() throws XPathException
endElement
in interface Receiver
endElement
in class ProxyReceiver
XPathException
- if the element is invalidCopyright (c) 2004-2014 Saxonica Limited. All rights reserved.