|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.daisy.zedval.ZedVal
Main application class.
To run ZedVal using default (provided) test maps:
Java -jar ZedVal.jar D:/myDtb/package.opf
For more information on options, run Java -jar ZedVal.jar -help
Use of the instantiation convenience methods:
public class ZedComponent implements ZedReporter {
//....
Zedval zv = new ZedVal();
try {
zv.setReporter(this);
zv.validate(opfFile);
} catch (ZedContextException e) {
//...
} catch (ZedFileInitializationException e) {
//...
}
//implement the ZedReporter interface
public void addMessage(ZedMessage m) throws ZedReporterException {
if (m instanceof FailureMessage) {
//...
}else{
System.out.println(m.getText());
}
}
}
Constructor Summary | |
ZedVal()
Constructor when using ZedVal as a component. |
Method Summary | |
DefaultContext |
getContext()
|
static java.lang.String |
getVersion()
|
static void |
main(java.lang.String[] args)
|
void |
sendApplicationErrMsg(java.lang.String msg,
boolean fatal,
java.lang.String context)
Constructs and sends an ApplicationErrMsg to the Reporter, if available. |
void |
setReporter(ZedReporter zr)
Convenience method to register a reporter when using ZedVal as a reporter. |
void |
validate(java.io.File opf)
Convenience method when using ZedVal as a component. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ZedVal()
Method Detail |
public static void main(java.lang.String[] args) throws java.lang.Exception
java.lang.Exception
public void setReporter(ZedReporter zr) throws ZedContextException
ZedContextException
public void validate(java.io.File opf) throws ZedContextException, ZedFileInitializationException
Convenience method when using ZedVal as a component.
This method is reentrant: several validate() calls can be made on the same ZedVal instance.
If the user has not specified custom test- or processor maps to use prior to calling this method, the default (provided) maps will be used.
If this method does not throw an Exception, validation was completed succssfully.
ZedContextException
ZedFileInitializationException
public DefaultContext getContext()
public void sendApplicationErrMsg(java.lang.String msg, boolean fatal, java.lang.String context)
msg
- The message textfatal
- Is the error fatal?context
- String expressing application contextpublic static java.lang.String getVersion()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |