org.jopendocument.util
Class Validator

java.lang.Object
  extended by org.jopendocument.util.Validator
Direct Known Subclasses:
Validator.DTDValidator, Validator.JAXPValidator

public abstract class Validator
extends java.lang.Object


Nested Class Summary
static class Validator.DTDValidator
           
static class Validator.JAXPValidator
           
 
Method Summary
abstract  java.lang.String isValid()
          Validate a document, stopping at the first problem.
abstract  CollectionMap<java.lang.String,java.lang.String> validateCompletely()
          Validate the whole document.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

isValid

public abstract java.lang.String isValid()
Validate a document, stopping at the first problem.

Returns:
null if doc is valid, a String describing the first problem otherwise.

validateCompletely

public abstract CollectionMap<java.lang.String,java.lang.String> validateCompletely()
Validate the whole document.

Returns:
all problems (with line number) indexed by type, e.g. ERROR unexpected attribute "style:join-border" => [on line 22:50, on line 14901:290].