Free Trial - Stylus Studio, The World's Best XML IDE!


com.saxonica.validate
Class LaxValidator

java.lang.Object
  |
  +--net.sf.saxon.event.ProxyReceiver
        |
        +--com.saxonica.validate.Validator
              |
              +--com.saxonica.validate.LaxValidator
All Implemented Interfaces:
Receiver, javax.xml.transform.Result, javax.xml.transform.SourceLocator
Direct Known Subclasses:
AnyTypeValidator

public class LaxValidator
extends Validator

This class performs lax validation on an element.


Field Summary
 
Fields inherited from class com.saxonica.validate.Validator
xsiType
 
Fields inherited from class net.sf.saxon.event.ProxyReceiver
baseReceiver, config, systemId
 
Fields inherited from interface javax.xml.transform.Result
PI_DISABLE_OUTPUT_ESCAPING, PI_ENABLE_OUTPUT_ESCAPING
 
Constructor Summary
LaxValidator()
           
 
Method Summary
 void attribute(int nameCode, int typeCode, java.lang.CharSequence value, int properties)
          Handle an attribute
 Validator getChildValidator()
          Get a validator to handle the children of the current element.
 int getTypeAnnotation()
          Get the type annotation to be used for an element or attribute that conforms to the type being validated against
protected  SequenceReceiver processChildElement(int nameCode, int properties)
          Perform validation actions at the start of a child element
 void startElement(int nameCode, int typeCode, int properties)
          Output element start tag
 
Methods inherited from class com.saxonica.validate.Validator
checkDerivation, getAnnotation, getColumnNumber, getContainingElement, getContainingElementName, getElementDeclaration, getLineNumber, getNamespaceResolver, getPublicId, getSystemId, isNillable, makeValidator, makeValidator, makeValidator, setAnnotation, setContainingElement, setDocumentLocator, setElementDeclaration, setNamespaceResolver, setNillable, setXSIType
 
Methods inherited from class net.sf.saxon.event.ProxyReceiver
characters, comment, endDocument, endElement, getConfiguration, getNamePool, getUnderlyingReceiver, namespace, processingInstruction, setConfiguration, setSystemId, setUnderlyingReceiver, setUnparsedEntity, startContent, startDocument
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface net.sf.saxon.event.Receiver
characters, comment, endDocument, endElement, getConfiguration, namespace, processingInstruction, setConfiguration, setSystemId, setUnparsedEntity, startContent, startDocument
 

Constructor Detail

LaxValidator

public LaxValidator()
Method Detail

getTypeAnnotation

public int getTypeAnnotation()
Get the type annotation to be used for an element or attribute that conforms to the type being validated against

Specified by:
getTypeAnnotation in class Validator

startElement

public void startElement(int nameCode,
                         int typeCode,
                         int properties)
                  throws javax.xml.transform.TransformerException
Output element start tag

Specified by:
startElement in interface Receiver
Overrides:
startElement in class Validator
Parameters:
nameCode - integer code identifying the name of the element within the name pool.
typeCode - integer code identifying the element's type within the name pool.
javax.xml.transform.TransformerException

getChildValidator

public Validator getChildValidator()
Description copied from class: Validator
Get a validator to handle the children of the current element. This is called immediately on return from the startElement call that starts this element.

Specified by:
getChildValidator in class Validator

processChildElement

protected SequenceReceiver processChildElement(int nameCode,
                                               int properties)
                                        throws javax.xml.transform.TransformerException
Perform validation actions at the start of a child element

javax.xml.transform.TransformerException

attribute

public void attribute(int nameCode,
                      int typeCode,
                      java.lang.CharSequence value,
                      int properties)
               throws javax.xml.transform.TransformerException
Handle an attribute

Specified by:
attribute in interface Receiver
Overrides:
attribute in class ProxyReceiver
Parameters:
nameCode - integer identifying the name of the attribute
typeCode - integer identifying the type annotation of the attribute
value - the value of the attribute
properties - bit-significant flags indicating special action to be taken
Throws:
javax.xml.transform.TransformerException - On any failure to write the attribute


Stylus Studio features integrated development and debugging support for Saxon in the XQuery editor and XSLT editor.