|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--dk.brics.dsd.Validator
DSD 2.0 validator.
Constructor Summary | |
Validator(ValidationErrorHandler handler)
Constructs a new DSD 2.0 validator. |
Method Summary | |
static String |
findDSDref(Document doc)
Finds DSD processing instruction in XML document. |
static Document |
makeDocument(String str,
URL context)
Builds an XML document from a String and expands XInclude instructions. |
static Document |
makeDocument(URL url)
Retrieves an XML document from a URL and expands XInclude instructions. |
Document |
process(Document app,
Schema dsd)
Processes an XML document with a DSD 2.0 schema. |
Document |
process(Document app,
Schema dsd,
boolean weak)
Processes an XML document with a DSD 2.0 schema. |
void |
process(Graph sg,
Schema dsd)
Processes a JWIG summary graph with a DSD 2.0 schema. |
void |
setRepeatMin(boolean enable)
Sets repeat-min flag. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Validator(ValidationErrorHandler handler)
handler
- validation error handlerMethod Detail |
public static String findDSDref(Document doc)
doc
- XML document
public static Document makeDocument(String str, URL context) throws JDOMException, MalformedURLException
str
- XML documentcontext
- URL context for resolving relative URLs (null if none)
JDOMException
- if an error occured during JDOM parsing or XInclude expansion
MalformedURLException
- if a malformed URL appears in an XInclude instructionpublic static Document makeDocument(URL url) throws JDOMException, MalformedURLException
url
- URL of XML document
JDOMException
- if an error occured during JDOM parsing or XInclude expansion
MalformedURLException
- if a malformed URL appears in an XInclude instructionpublic Document process(Document app, Schema dsd) throws SchemaErrorException
app
- application document to be validateddsd
- DSD schema document
error
elements if not valid
SchemaErrorException
- if a fatal error in the DSD is encounteredpublic Document process(Document app, Schema dsd, boolean weak) throws SchemaErrorException
app
- application document to be validateddsd
- DSD schema documentweak
- if true, omit uniqueness and pointer checking
error
elements if not valid
SchemaErrorException
- if a fatal error in the DSD is encounteredpublic void process(Graph sg, Schema dsd) throws SchemaErrorException
sg
- summary graph to be validateddsd
- DSD schema document
SchemaErrorException
- if a fatal error in the DSD is encounteredpublic void setRepeatMin(boolean enable)
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |