public class SimpleXsdSchema extends Object implements XsdSchema, org.springframework.beans.factory.InitializingBean
XsdSchema implementation.
Allows a XSD to be set by the setXsd(Resource), or directly in the constructor.| Constructor and Description |
|---|
SimpleXsdSchema()
Create a new instance of the
SimpleXsdSchema class. |
SimpleXsdSchema(org.springframework.core.io.Resource xsdResource)
Create a new instance of the
SimpleXsdSchema class with the specified resource. |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
XmlValidator |
createValidator()
Creates a
XmlValidator based on the schema. |
Source |
getSource()
Returns the
Source of the schema. |
String |
getTargetNamespace()
Returns the target namespace of this schema.
|
void |
setXsd(org.springframework.core.io.Resource xsdResource)
Set the XSD resource to be exposed by calls to this instances'
getSource() method. |
String |
toString() |
public SimpleXsdSchema()
SimpleXsdSchema class.
A subsequent call to the setXsd(Resource) method is required.public SimpleXsdSchema(org.springframework.core.io.Resource xsdResource)
SimpleXsdSchema class with the specified resource.xsdResource - the XSD resource; must not be nullIllegalArgumentException - if the supplied xsdResource is nullpublic void setXsd(org.springframework.core.io.Resource xsdResource)
getSource() method.xsdResource - the XSD resourcepublic String getTargetNamespace()
XsdSchemagetTargetNamespace in interface XsdSchemapublic Source getSource()
XsdSchemaSource of the schema.public XmlValidator createValidator() throws IOException
XsdSchemaXmlValidator based on the schema.createValidator in interface XsdSchemaIOException - in case of I/O errorspublic void afterPropertiesSet()
throws ParserConfigurationException,
IOException,
SAXException
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanParserConfigurationExceptionIOExceptionSAXExceptionCopyright © 2005–2015 The Spring Web Services Framework. All rights reserved.