Home » xmlbeans-2.5.0-src » org.apache.xmlbeans.impl » validator » [javadoc | source]
public class: ValidatingXMLStreamReader [javadoc | source]

All Implemented Interfaces:

Direct Known Subclasses:

This class is a wrapper over a generic XMLStreamReader that provides validation. There are 3 cases:
1) the XMLStreamReader represents a document, it contains only one element document - in this case the user schema type should be null or it should be a document SchemaType
2) the XMLStreamReader represents an xml-fragment (content only) - must have at least one user type or xsi:type
a) it has an xsi:type - if user schema type is available it has to be a base type of xsi:type
b) it doesn't have xsi:type - user must provide a schema type otherwise will error and will not do validation
3) the XMLStreamReader represents a global attribute - i.e. user schema type is null and only one attribute
Field Summary
protected  Validator _validator     
 public ValidatingXMLStreamReader() 
Method from org.apache.xmlbeans.impl.validator.ValidatingXMLStreamReader Summary:
getProperty,   init,   isValid,   next,   validate_attribute,   validate_attributes
Methods from javax.xml.stream.util.StreamReaderDelegate:
close,   getAttributeCount,   getAttributeLocalName,   getAttributeName,   getAttributeNamespace,   getAttributePrefix,   getAttributeType,   getAttributeValue,   getAttributeValue,   getCharacterEncodingScheme,   getElementText,   getEncoding,   getEventType,   getLocalName,   getLocation,   getName,   getNamespaceContext,   getNamespaceCount,   getNamespacePrefix,   getNamespaceURI,   getNamespaceURI,   getNamespaceURI,   getPIData,   getPITarget,   getParent,   getPrefix,   getProperty,   getText,   getTextCharacters,   getTextCharacters,   getTextLength,   getTextStart,   getVersion,   hasName,   hasNext,   hasText,   isAttributeSpecified,   isCharacters,   isEndElement,   isStandalone,   isStartElement,   isWhiteSpace,   next,   nextTag,   require,   setParent,   standaloneSet
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.xmlbeans.impl.validator.ValidatingXMLStreamReader Detail:
 public Object getProperty(String s) throws IllegalArgumentException 
 public  void init(XMLStreamReader xsr,
    boolean startWithCurrentEvent,
    SchemaType contentType,
    SchemaTypeLoader stl,
    XmlOptions options,
    Collection errorListener) 
    Used in case of reusing the same ValidatinXMLStreamReader object
 public boolean isValid() 
 public int next() throws XMLStreamException 
 protected  void validate_attribute(int attIndex) 
 protected  void validate_attributes(int attCount)