package org.wamblee.xmlrouter.config; import javax.xml.transform.dom.DOMSource; public interface DocumentType { /** * Symbolic name for the document type. * @return Name. */ String getName(); /** * Checks if a document is of the given type. * @param aSource Document * @return True iff the document is of the given type. */ boolean isInstance(DOMSource aSource); /** * Validates the document. Implementations that do not validate should simply * return true always. * @param aSource Document. * @return True iff the document is valid. */ boolean validate(DOMSource aSource); }