|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.saxonica.Validate
public class Validate
This Validate class provides a command line interface that allows validation of a source document against a schema, and/or checking that a source schema is a valid schema.
Apart from error and optional progress messages, no output is produced.
| Field Summary | |
|---|---|
protected EnterpriseConfiguration |
config
|
protected Controller |
controller
|
protected int |
repeat
|
protected boolean |
showTime
|
protected StatisticsReporter |
statsReporter
|
protected String |
topLevelElementName
|
protected boolean |
useURLs
|
protected int |
validationMode
|
protected int |
xsdLanguageVersion
|
| Constructor Summary | |
|---|---|
Validate()
|
|
| Method Summary | |
|---|---|
protected void |
applyLocalOptions(CommandLineOptions options,
Configuration config)
Customisation hook: apply options defined locally in a subclass |
protected void |
badUsage(String message)
Report incorrect usage of the command line, with a list of the options and arguments that are available |
protected void |
doValidate(String[] args)
Support method for main program. |
static Source |
loadDocument(String sourceFileName,
boolean useURLs,
Configuration config)
Load a document, given a filename or URL |
static void |
main(String[] args)
Main program, can be used directly from the command line. |
void |
processFile(Source source)
Process a single file using a supplied schema |
protected static void |
quit(String message,
int code)
Exit with a message |
protected void |
setConfiguration()
Create the configuration. |
void |
setPermittedOptions(CommandLineOptions options)
Set the options that are recognized on the command line. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected EnterpriseConfiguration config
protected Controller controller
protected boolean useURLs
protected boolean showTime
protected int repeat
protected int validationMode
protected int xsdLanguageVersion
protected String topLevelElementName
protected StatisticsReporter statsReporter
| Constructor Detail |
|---|
public Validate()
| Method Detail |
|---|
public static void main(String[] args)
throws Exception
args - List of arguments supplied on operating system command line
Exception - Indicates that a compile-time or
run-time error occurredprotected void setConfiguration()
public void setPermittedOptions(CommandLineOptions options)
options - the CommandLineOptions in which the recognized options are to be registered.protected void doValidate(String[] args)
args - the command-line arguments
protected void applyLocalOptions(CommandLineOptions options,
Configuration config)
options - the CommandLineOptionsconfig - the Saxon Configuration
protected static void quit(String message,
int code)
message - The message to be outputcode - The result code to be returned to the operating
system shell
public static Source loadDocument(String sourceFileName,
boolean useURLs,
Configuration config)
throws TransformerException
sourceFileName - the name of the source fileuseURLs - true if name is to be treated as a URIconfig - the Saxon configuration
TransformerException - if a document cannot be loaded
public void processFile(Source source)
throws TransformerException
source - The source XML document to be transformed
TransformerException - If the transformation failsprotected void badUsage(String message)
message - The error message
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||