Package com.ctc.wstx.dtd
Class DTDSchemaFactory
- java.lang.Object
-
- org.codehaus.stax2.validation.XMLValidationSchemaFactory
-
- com.ctc.wstx.dtd.DTDSchemaFactory
-
public class DTDSchemaFactory extends XMLValidationSchemaFactory
Factory for creating DTD validator schema objects (shareable stateless "blueprints" for creating actual validators).Due to close coupling of XML and DTD, some of the functionality implemented (like that of reading internal subsets embedded in XML documents) is only accessible by core Woodstox. The externally accessible
-
-
Field Summary
Fields Modifier and Type Field Description protected ReaderConfigmReaderConfigThis configuration object is used (instead of a more specific one) since the actual DTD reader uses such configuration object.protected ValidatorConfigmSchemaConfigCurrent configurations for this factory-
Fields inherited from class org.codehaus.stax2.validation.XMLValidationSchemaFactory
INTERNAL_ID_SCHEMA_DTD, INTERNAL_ID_SCHEMA_RELAXNG, INTERNAL_ID_SCHEMA_TREX, INTERNAL_ID_SCHEMA_W3C, mSchemaType, P_ENABLE_CACHING, P_IS_NAMESPACE_AWARE, SERVICE_DEFINITION_PATH, SYSTEM_PROPERTY_FOR_IMPL
-
-
Constructor Summary
Constructors Constructor Description DTDSchemaFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description XMLValidationSchemacreateSchema(File f)XMLValidationSchemacreateSchema(InputStream in, String encoding, String publicId, String systemId)XMLValidationSchemacreateSchema(Reader r, String publicId, String systemId)XMLValidationSchemacreateSchema(URL url)protected XMLValidationSchemadoCreateSchema(ReaderConfig rcfg, InputBootstrapper bs, String publicId, String systemIdStr, URL ctxt)The main validator construction method, called by all externally visible methods.ObjectgetProperty(String propName)booleanisPropertySupported(String propName)booleansetProperty(String propName, Object value)-
Methods inherited from class org.codehaus.stax2.validation.XMLValidationSchemaFactory
createSchema, createSchema, createSchema, getSchemaType, newInstance, newInstance
-
-
-
-
Field Detail
-
mSchemaConfig
protected final ValidatorConfig mSchemaConfig
Current configurations for this factory
-
mReaderConfig
protected final ReaderConfig mReaderConfig
This configuration object is used (instead of a more specific one) since the actual DTD reader uses such configuration object.
-
-
Method Detail
-
isPropertySupported
public boolean isPropertySupported(String propName)
- Specified by:
isPropertySupportedin classXMLValidationSchemaFactory
-
setProperty
public boolean setProperty(String propName, Object value)
- Specified by:
setPropertyin classXMLValidationSchemaFactory- Parameters:
propName- Name of property to setvalue- Value to set property to- Returns:
- True if setting succeeded; false if property was recognized but could not be changed to specified value, or if it was not recognized but the implementation did not throw an exception.
-
getProperty
public Object getProperty(String propName)
- Specified by:
getPropertyin classXMLValidationSchemaFactory
-
createSchema
public XMLValidationSchema createSchema(InputStream in, String encoding, String publicId, String systemId) throws XMLStreamException
- Specified by:
createSchemain classXMLValidationSchemaFactory- Throws:
XMLStreamException
-
createSchema
public XMLValidationSchema createSchema(Reader r, String publicId, String systemId) throws XMLStreamException
- Specified by:
createSchemain classXMLValidationSchemaFactory- Throws:
XMLStreamException
-
createSchema
public XMLValidationSchema createSchema(URL url) throws XMLStreamException
- Specified by:
createSchemain classXMLValidationSchemaFactory- Throws:
XMLStreamException
-
createSchema
public XMLValidationSchema createSchema(File f) throws XMLStreamException
- Specified by:
createSchemain classXMLValidationSchemaFactory- Throws:
XMLStreamException
-
doCreateSchema
protected XMLValidationSchema doCreateSchema(ReaderConfig rcfg, InputBootstrapper bs, String publicId, String systemIdStr, URL ctxt) throws XMLStreamException
The main validator construction method, called by all externally visible methods.- Throws:
XMLStreamException
-
-