|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectfedora.server.validation.DOValidatorSchematron
Title: DOValidatorSchematron.java
Description: Schematron validation for fedora objects encoded in schematron schema for Fedora. The schematron schema (metsExtRules1-0.xml) expresses a set of rules using XPATH that enable us to check for things that are either not expressed in the METS XML schema, or that cannot be expressed with XML Schema language. Generally we will look for things that are requirements of Fedora objects, which are not requirements for METS objects in general.
-----------------------------------------------------------------------------License and Copyright: The contents of this file are subject to the Mozilla Public License Version 1.1 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.mozilla.org/MPL/.
Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
The entire file consists of original code. Copyright © 2002-2005 by The Rector and Visitors of the University of Virginia and Cornell University. All rights reserved.
-----------------------------------------------------------------------------
| Constructor Summary | |
DOValidatorSchematron(java.lang.String schemaPath,
java.lang.String preprocessorPath,
java.lang.String phase)
Constructs a DOValidatorSchematron instance with a Schematron preprocessor that is provided by the calling class. |
|
| Method Summary | |
static javax.xml.transform.stream.StreamSource |
fileToStreamSource(java.io.File file)
|
static javax.xml.transform.stream.StreamSource |
fileToStreamSource(java.lang.String str)
Generates a StreamSource from a file name. |
void |
validate(java.io.File objectAsFile)
Run the Schematron validation on a Fedora object. |
void |
validate(java.io.InputStream objectAsStream)
Run the Schematron validation on a Fedora object. |
void |
validate(javax.xml.transform.stream.StreamSource objectSource)
Run the Schematron validation on a Fedora object. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public DOValidatorSchematron(java.lang.String schemaPath,
java.lang.String preprocessorPath,
java.lang.String phase)
throws ObjectValidityException
schemaPath - the URL of the Schematron schemapreprocessorPath - the location of the Schematron preprocessorphase - the phase in the fedora object lifecycle to which
validation should pertain. (Currently options are
"ingest" and "store"
ObjectValidityException| Method Detail |
public void validate(java.io.File objectAsFile)
throws ServerException
objectAsFile - the Fedora object as a File
ServerException
public void validate(java.io.InputStream objectAsStream)
throws ServerException
objectAsStream - the Fedora object as an Inputstream
ServerException
public void validate(javax.xml.transform.stream.StreamSource objectSource)
throws ServerException
objectSource - the Fedora object as an StreamSource
ServerExceptionpublic static javax.xml.transform.stream.StreamSource fileToStreamSource(java.lang.String str)
public static javax.xml.transform.stream.StreamSource fileToStreamSource(java.io.File file)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||