public class PrideXmlValidator
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static org.iso_relax.verifier.VerifierFactory |
VERIFIER_FACTORY
The verifier factory.
|
| Constructor and Description |
|---|
PrideXmlValidator()
Set up a PrideXmlValidator using the default schema.
|
PrideXmlValidator(java.net.URL schemaUrl)
Set up a PrideXmlValidator using the provided schema.
|
| Modifier and Type | Method and Description |
|---|---|
XMLValidationErrorHandler |
getErrors()
Returns the XML validation error object.
|
java.lang.String |
getErrorsAsString()
Returns the errors formatted as s single string.
|
void |
setSchema(java.net.URL schemaUrl)
Set the schema.
|
boolean |
validate(java.io.File prideXmlFile)
Returns true of the given PRIDE XML file is valid.
|
public static final org.iso_relax.verifier.VerifierFactory VERIFIER_FACTORY
public PrideXmlValidator()
throws java.io.IOException,
org.iso_relax.verifier.VerifierConfigurationException,
org.xml.sax.SAXException
java.io.IOExceptionorg.iso_relax.verifier.VerifierConfigurationExceptionorg.xml.sax.SAXExceptionpublic PrideXmlValidator(java.net.URL schemaUrl)
throws java.io.IOException,
org.iso_relax.verifier.VerifierConfigurationException,
org.xml.sax.SAXException
schemaUrl - the URL to the schemajava.io.IOExceptionorg.iso_relax.verifier.VerifierConfigurationExceptionorg.xml.sax.SAXExceptionpublic void setSchema(java.net.URL schemaUrl)
throws java.io.IOException,
org.iso_relax.verifier.VerifierConfigurationException,
org.xml.sax.SAXException
schemaUrl - the schema to setjava.io.IOExceptionorg.iso_relax.verifier.VerifierConfigurationExceptionorg.xml.sax.SAXExceptionpublic boolean validate(java.io.File prideXmlFile)
throws java.io.FileNotFoundException,
java.io.IOException,
org.iso_relax.verifier.VerifierConfigurationException,
org.xml.sax.SAXException
prideXmlFile - the PRIDE XML file to testjava.io.FileNotFoundExceptionjava.io.IOExceptionorg.iso_relax.verifier.VerifierConfigurationExceptionorg.xml.sax.SAXExceptionpublic java.lang.String getErrorsAsString()
public XMLValidationErrorHandler getErrors()
Copyright © 2014. All Rights Reserved.