net.n3.nanoxml
public class ValidatorPlugin extends Object implements IXMLValidator
Version: $Name: RELEASE_2_2_1 $, $Revision: 1.3 $
Constructor Summary | |
---|---|
ValidatorPlugin()
Initializes the plugin. |
Method Summary | |
---|---|
void | attributeAdded(String key, String value, String systemId, int lineNr)
This method is called when the attributes of an XML element have been
processed.
|
void | elementAttributesProcessed(String name, Properties extraAttributes, String systemId, int lineNr)
Indicates that an attribute has been added to the current element.
|
void | elementEnded(String name, String systemId, int lineNr)
Indicates that the current element has ended.
|
void | elementStarted(String name, String systemId, int lineNr)
Indicates that an element has been started.
|
protected void | finalize()
Cleans up the object when it's destroyed. |
IXMLValidator | getDelegate()
Returns the delegate. |
IXMLEntityResolver | getParameterEntityResolver()
Returns the parameter entity resolver.
|
void | invalidAttributeValue(String systemID, int lineNr, String elementName, String attributeName, String attributeValue)
Throws an XMLValidationException to indicate that an attribute has an
invalid value.
|
void | missingAttribute(String systemID, int lineNr, String elementName, String attributeName)
Throws an XMLValidationException to indicate that an attribute is
missing.
|
void | missingElement(String systemID, int lineNr, String parentElementName, String missingElementName)
Throws an XMLValidationException to indicate that an element is missing.
|
void | missingPCData(String systemID, int lineNr, String parentElementName)
Throws an XMLValidationException to indicate that a #PCDATA element was
missing.
|
void | parseDTD(String publicID, IXMLReader reader, IXMLEntityResolver entityResolver, boolean external)
Parses the DTD. |
void | PCDataAdded(String systemId, int lineNr)
Indicates that a new #PCDATA element has been encountered.
|
void | setDelegate(IXMLValidator delegate)
Sets the delegate.
|
void | setParameterEntityResolver(IXMLEntityResolver resolver)
Sets the parameter entity resolver.
|
void | unexpectedAttribute(String systemID, int lineNr, String elementName, String attributeName)
Throws an XMLValidationException to indicate that an attribute is
unexpected.
|
void | unexpectedElement(String systemID, int lineNr, String parentElementName, String unexpectedElementName)
Throws an XMLValidationException to indicate that an element is
unexpected.
|
void | unexpectedPCData(String systemID, int lineNr, String parentElementName)
Throws an XMLValidationException to indicate that a #PCDATA element was
unexpected.
|
void | validationError(String systemID, int lineNr, String message, String elementName, String attributeName, String attributeValue)
Throws an XMLValidationException.
|
Parameters: name the name of the element. extraAttributes where to put extra attributes. systemId the system ID of the XML data of the element. lineNr the line number in the XML data of the element.
Throws: java.lang.Exception if the element could not be validated.
Parameters: key the name of the attribute. value the value of the attribute. systemId the system ID of the XML data of the element. lineNr the line number in the XML data of the element.
Throws: java.lang.Exception if the attribute could not be validated.
Parameters: name the name of the element. systemId the system ID of the XML data of the element. lineNr the line number in the XML data of the element.
Throws: java.lang.Exception if the element could not be validated.
Parameters: name the name of the element. systemId the system ID of the XML data of the element. lineNr the line number in the XML data of the element.
Throws: java.lang.Exception if the element could not be validated.
Returns: the entity resolver.
Parameters: systemID the system ID of the XML data of the element lineNr the line number in the XML data of the element elementName the name of the element attributeName the name of the attribute attributeValue the value of the attribute
Throws: net.n3.nanoxml.XMLValidationException of course :-)
Parameters: systemID the system ID of the XML data of the element lineNr the line number in the XML data of the element elementName the name of the element attributeName the name of the missing attribute
Throws: net.n3.nanoxml.XMLValidationException of course :-)
Parameters: systemID the system ID of the XML data of the element lineNr the line number in the XML data of the element parentElementName the name of the parent element missingElementName the name of the missing element
Throws: net.n3.nanoxml.XMLValidationException of course :-)
Parameters: systemID the system ID of the XML data of the element lineNr the line number in the XML data of the element parentElementName the name of the parent element
Throws: net.n3.nanoxml.XMLValidationException of course :-)
Parameters: publicID the public ID, which may be null. reader the reader to read the DTD from. entityResolver the entity resolver. external true if the DTD is external.
Throws: java.lang.Exception if something went wrong.
Parameters: systemId the system ID of the XML data of the element. lineNr the line number in the XML data of the element.
Throws: java.lang.Exception if the element could not be validated.
Parameters: delegate the delegate
Parameters: resolver the entity resolver.
Parameters: systemID the system ID of the XML data of the element lineNr the line number in the XML data of the element elementName the name of the element attributeName the name of the unexpected attribute
Throws: net.n3.nanoxml.XMLValidationException of course :-)
Parameters: systemID the system ID of the XML data of the element lineNr the line number in the XML data of the element parentElementName the name of the parent element unexpectedElementName the name of the missing element
Throws: net.n3.nanoxml.XMLValidationException of course :-)
Parameters: systemID the system ID of the XML data of the element lineNr the line number in the XML data of the element parentElementName the name of the parent element
Throws: net.n3.nanoxml.XMLValidationException of course :-)
Parameters: systemID the system ID of the XML data of the element lineNr the line number in the XML data of the element message the error message elementName the name of the element (may be null) attributeName the name of the attribute (may be null) attributeValue the value of the attribute (may be null)
Throws: net.n3.nanoxml.XMLValidationException of course :-)