public abstract class AbstractValidatingXMLObject extends AbstractXMLObject implements ValidatingXMLObject
AbstractXMLObject that implements
ValidatingXMLObject.| Modifier | Constructor and Description |
|---|---|
protected |
AbstractValidatingXMLObject(String namespaceURI,
String elementLocalName,
String namespacePrefix)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
deregisterValidator(Validator validator)
Deregisters a validator for this XMLObject.
|
List<Validator> |
getValidators()
Gets the list of validators for this XMLObject or null if there is no list.
|
void |
registerValidator(Validator validator)
Registers a validator for this XMLObject.
|
void |
validate(boolean validateDescendants)
Validates this XMLObject against all registered validators.
|
protected void |
validateChildren(XMLObject xmlObject)
Recursive method used to validate all the children of the given XMLObject that implement
ValidatingXMLObject. |
addNamespace, detach, getDOM, getElementQName, getIDIndex, getNamespaceManager, getNamespaces, getNoNamespaceSchemaLocation, getParent, getSchemaLocation, getSchemaType, hasChildren, hasParent, isNil, isNilXSBoolean, manageQualifiedAttributeNamespace, prepareAttributeValueForAssignment, prepareElementContentForAssignment, prepareForAssignment, prepareForAssignment, prepareForAssignment, prepareForAssignment, registerOwnID, releaseChildrenDOM, releaseDOM, releaseParentDOM, releaseThisAndChildrenDOM, releaseThisandParentDOM, removeNamespace, resolveID, resolveIDFromRoot, setDOM, setElementNamespacePrefix, setElementQName, setNil, setNil, setNoNamespaceSchemaLocation, setParent, setSchemaLocation, setSchemaTypeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddNamespace, detach, getDOM, getElementQName, getIDIndex, getNamespaceManager, getNamespaces, getNoNamespaceSchemaLocation, getOrderedChildren, getParent, getSchemaLocation, getSchemaType, hasChildren, hasParent, isNil, isNilXSBoolean, releaseChildrenDOM, releaseDOM, releaseParentDOM, removeNamespace, resolveID, resolveIDFromRoot, setDOM, setNil, setNil, setNoNamespaceSchemaLocation, setParent, setSchemaLocationprotected AbstractValidatingXMLObject(String namespaceURI, String elementLocalName, String namespacePrefix)
namespaceURI - the namespace the element is inelementLocalName - the local name of the XML element this Object representsnamespacePrefix - the prefix for the given namespacepublic List<Validator> getValidators()
getValidators in interface ValidatingXMLObjectpublic void registerValidator(Validator validator)
registerValidator in interface ValidatingXMLObjectvalidator - the validatorpublic void deregisterValidator(Validator validator)
deregisterValidator in interface ValidatingXMLObjectvalidator - the validatorpublic void validate(boolean validateDescendants)
throws ValidationException
validate in interface ValidatingXMLObjectvalidateDescendants - true if all the descendants of this object should
be validated as well, false if notValidationException - thrown if the element is not validprotected void validateChildren(XMLObject xmlObject) throws ValidationException
ValidatingXMLObject. Note, this can be a very expensive operation.xmlObject - xmlObject whose descendants should be validatedValidationException - thrown if any child objects are not validCopyright © 2018 JBoss by Red Hat. All rights reserved.