|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.iso_relax.verifier.VerifierFactory
VerifierFactory
Constructor Summary | |
VerifierFactory()
|
Method Summary | |
Schema |
compileSchema(java.io.File f)
processes a schema into a Schema object, which is a compiled representation of a schema. |
abstract Schema |
compileSchema(InputSource is)
processes a schema into a Schema object, which is a compiled representation of a schema. |
Schema |
compileSchema(java.io.InputStream stream)
processes a schema into a Schema object, which is a compiled representation of a schema. |
Schema |
compileSchema(java.io.InputStream stream,
java.lang.String systemId)
processes a schema into a Schema object, which is a compiled representation of a schema. |
Schema |
compileSchema(java.lang.String url)
processes a schema into a Schema object, which is a compiled representation of a schema. |
EntityResolver |
getEntityResolver()
Gets the current entity resolver, which was set by the SetEntityResolver method. |
java.lang.Object |
getProperty(java.lang.String property)
Gets property value |
boolean |
isFeature(java.lang.String feature)
Indicates whether if the feature is supported, or not. |
static VerifierFactory |
newInstance()
Deprecated. |
static VerifierFactory |
newInstance(java.lang.String language)
|
static VerifierFactory |
newInstance(java.lang.String language,
java.lang.ClassLoader classLoader)
Creates a new instance of a VerifierFactory for the specified schema language. |
Verifier |
newVerifier(java.io.File file)
parses a schema from the specified file and returns a Verifier object that validates documents by using that schema. |
Verifier |
newVerifier(InputSource source)
parses a schema from the specified InputSource and returns a Verifier object that validates documents by using that schema. |
Verifier |
newVerifier(java.io.InputStream stream)
parses a schema from the specified InputStream and returns a Verifier object that validates documents by using that schema. |
Verifier |
newVerifier(java.io.InputStream stream,
java.lang.String systemId)
parses a schema from the specified InputStream and returns a Verifier object that validates documents by using that schema. |
Verifier |
newVerifier(java.lang.String uri)
parses a schema at the specified location and returns a Verifier object that validates documents by using that schema. |
void |
setEntityResolver(EntityResolver _resolver)
Sets an EntityResolver This entity resolver is used to resolve entities encountered while parsing a schema. |
void |
setFeature(java.lang.String feature,
boolean value)
Sets feature value |
void |
setProperty(java.lang.String property,
java.lang.Object value)
Sets property value |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public VerifierFactory()
Method Detail |
public Verifier newVerifier(java.lang.String uri) throws VerifierConfigurationException, SAXException, java.io.IOException
Some of XML parsers accepts filenames as well as URLs, while others reject them. Therefore, to parse a file as a schema, you should use a File object.
uri
- URI of a schema file
VerifierConfigurationException
SAXException
java.io.IOException
public Verifier newVerifier(java.io.File file) throws VerifierConfigurationException, SAXException, java.io.IOException
VerifierConfigurationException
SAXException
java.io.IOException
public Verifier newVerifier(java.io.InputStream stream) throws VerifierConfigurationException, SAXException, java.io.IOException
VerifierConfigurationException
SAXException
java.io.IOException
public Verifier newVerifier(java.io.InputStream stream, java.lang.String systemId) throws VerifierConfigurationException, SAXException, java.io.IOException
systemId
- System ID of this stream.
VerifierConfigurationException
SAXException
java.io.IOException
public Verifier newVerifier(InputSource source) throws VerifierConfigurationException, SAXException, java.io.IOException
source
- InputSource of a schema file
VerifierConfigurationException
SAXException
java.io.IOException
public abstract Schema compileSchema(InputSource is) throws VerifierConfigurationException, SAXException, java.io.IOException
VerifierConfigurationException
SAXException
java.io.IOException
public Schema compileSchema(java.lang.String url) throws VerifierConfigurationException, SAXException, java.io.IOException
Some of XML parsers accepts filenames as well as URLs, while others reject them. Therefore, to parse a file as a schema, you should use a File object.
url
- A source url of a schema file to be compiled.
VerifierConfigurationException
SAXException
java.io.IOException
public Schema compileSchema(java.io.InputStream stream) throws VerifierConfigurationException, SAXException, java.io.IOException
stream
- A stream object that holds a schema.
VerifierConfigurationException
SAXException
java.io.IOException
public Schema compileSchema(java.io.InputStream stream, java.lang.String systemId) throws VerifierConfigurationException, SAXException, java.io.IOException
systemId
- The system Id of this input stream.
VerifierConfigurationException
SAXException
java.io.IOException
public Schema compileSchema(java.io.File f) throws VerifierConfigurationException, SAXException, java.io.IOException
VerifierConfigurationException
SAXException
java.io.IOException
public boolean isFeature(java.lang.String feature) throws SAXNotRecognizedException, SAXNotSupportedException
feature
- feature name
SAXNotRecognizedException
SAXNotSupportedException
public void setFeature(java.lang.String feature, boolean value) throws SAXNotRecognizedException, SAXNotSupportedException
feature
- feature namevalue
- feature value
SAXNotRecognizedException
SAXNotSupportedException
public java.lang.Object getProperty(java.lang.String property) throws SAXNotRecognizedException, SAXNotSupportedException
property
- property name
SAXNotRecognizedException
SAXNotSupportedException
public void setProperty(java.lang.String property, java.lang.Object value) throws SAXNotRecognizedException, SAXNotSupportedException
property
- property namevalue
- property value
SAXNotRecognizedException
SAXNotSupportedException
public void setEntityResolver(EntityResolver _resolver)
public EntityResolver getEntityResolver()
SetEntityResolver
method.
public static VerifierFactory newInstance() throws VerifierConfigurationException
VerifierConfigurationException
public static VerifierFactory newInstance(java.lang.String language, java.lang.ClassLoader classLoader) throws VerifierConfigurationException
language
- URI that specifies the schema language.
It is preferable to use the namespace URI of the schema language to designate the schema language. For example,
URI | language |
http://relaxng.org/ns/structure/0.9 | RELAX NG |
http://www.xml.gr.jp/xmlns/relaxCore | RELAX Core |
http://www.xml.gr.jp/xmlns/relaxNamespace | RELAX Namespace |
http://www.thaiopensource.com/trex | TREX |
http://www.w3.org/2001/XMLSchema | W3C XML Schema |
http://www.w3.org/XML/1998/namespace | XML DTD |
classLoader
- This class loader is used to search the available implementation.
VerifierConfigurationException
- if no implementation is available for the specified language.public static VerifierFactory newInstance(java.lang.String language) throws VerifierConfigurationException
VerifierConfigurationException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |