Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.saxonica.sdoc
Class SchemaDocument

    java.lang.Object
      com.saxonica.sdoc.SchemaDocument

public class SchemaDocument
extends java.lang.Object

An XML document containing a module of an XML Schema

Constructor Summary
`SchemaDocument(DocumentInfo doc)` Create a SchemaDocument from a given document.

Method Summary
`DocumentInfo` | `getDocument()` Get the document wrapped by this SchemaDocument
`XSDSchema` | `getXSDSchema()` Get the xs:schema element within the schema document
`PreparedSchema` | `validate(javax.xml.transform.ErrorListener listener)` Validate the schema represented by this schema document

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### SchemaDocument

    public SchemaDocument(DocumentInfo doc)

  Create a SchemaDocument from a given document. This document must have been built using the SchemaNodeFactory

Parameters:
  `doc` - the document containing the xs:schema element

Method Detail

### getDocument

    public DocumentInfo getDocument()

  Get the document wrapped by this SchemaDocument

  Returns:
    the document

### getXSDSchema

    public XSDSchema getXSDSchema()

  Get the xs:schema element within the schema document

  Returns:
    the XSDSchema object representing the xs:schema element

### validate

    public PreparedSchema validate(javax.xml.transform.ErrorListener listener)
                            throws SchemaException

  Validate the schema represented by this schema document

  Parameters:
    `listener` - the ErrorListener: any error messages will be directed to this ErrorListener
  Returns:
    schema the schema, if it is valid
  Throws:
    `SchemaException` - if the schema is invalid

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD