org.apache.xerces.validators.dtd
Interface DTDValidator.EventHandler

All Known Implementing Classes:
XMLParser
Enclosing class:
DTDValidator

public static interface DTDValidator.EventHandler


Method Summary
 void attlistDecl(int elementType, int attrName, int attType, java.lang.String enumString, int attDefaultType, int attDefaultValue)
          callback for an attribute list declaration.
 void commentInDTD(int dataIndex)
          Callback for comment in DTD.
 void elementDecl(int elementType, XMLValidator.ContentSpec contentSpec)
          callback for an element declaration.
 void endDTD()
          callback for the end of the DTD This function will be called at the end of the DTD.
 void endNamespaceDeclScope(int prefix)
          callback for the end a namespace declaration scope.
 void externalEntityDecl(int entityName, int publicId, int systemId)
          callback for external general entity declaration.
 void externalPEDecl(int entityName, int publicId, int systemId)
          callback for an external parameter entity declaration.
 void internalEntityDecl(int entityName, int entityValue)
          callback for internal general entity declaration.
 void internalPEDecl(int entityName, int entityValue)
          callback for an internal parameter entity declaration.
 void internalSubset(int internalSubset)
          Supports DOM Level 2 internalSubset addition.
 void notationDecl(int notationName, int publicId, int systemId)
          callback for a notation declaration.
 void processingInstructionInDTD(int targetIndex, int dataIndex)
          Callback for processing instruction in DTD.
 void setValidating(boolean flag)
          Tell the handler that validation is happening
 void startDTD(int rootElementType, int publicId, int systemId)
          callback for the start of the DTD This function will be called when a <!DOCTYPE...> declaration is encountered.
 void startNamespaceDeclScope(int prefix, int uri)
          callback for the start of a namespace declaration scope.
 void unparsedEntityDecl(int entityName, int publicId, int systemId, int notationName)
          callback for an unparsed entity declaration.
 

Method Detail

setValidating

public void setValidating(boolean flag)
                   throws java.lang.Exception
Tell the handler that validation is happening
Parameters:
flag - true if validation is occuring

startDTD

public void startDTD(int rootElementType,
                     int publicId,
                     int systemId)
              throws java.lang.Exception
callback for the start of the DTD This function will be called when a <!DOCTYPE...> declaration is encountered.
Parameters:
rootElementType - element handle for the root element of the document
publicId - string pool index of the DTD's public ID
systemId - string pool index of the DTD's system ID
Throws:
java.lang.Exception -  

endDTD

public void endDTD()
            throws java.lang.Exception
callback for the end of the DTD This function will be called at the end of the DTD.

elementDecl

public void elementDecl(int elementType,
                        XMLValidator.ContentSpec contentSpec)
                 throws java.lang.Exception
callback for an element declaration.
Parameters:
elementType - element handle of the element being declared
contentSpec - contentSpec for the element being declared
Throws:
java.lang.Exception -  
See Also:
XMLValidator.ContentSpec

attlistDecl

public void attlistDecl(int elementType,
                        int attrName,
                        int attType,
                        java.lang.String enumString,
                        int attDefaultType,
                        int attDefaultValue)
                 throws java.lang.Exception
callback for an attribute list declaration.
Parameters:
elementType - element handle for the attribute's element
attrName - string pool index of the attribute name
attType - type of attribute
enumString - String representing the values of the enumeration, if the attribute is of enumerated type, or null if it is not.
attDefaultType - an integer value denoting the DefaultDecl value
attDefaultValue - string pool index of this attribute's default value or -1 if there is no defaultvalue
Throws:
java.lang.Exception -  

internalPEDecl

public void internalPEDecl(int entityName,
                           int entityValue)
                    throws java.lang.Exception
callback for an internal parameter entity declaration.
Parameters:
entityName - string pool index of the entity name
entityValue - string pool index of the entity replacement text
Throws:
java.lang.Exception -  

externalPEDecl

public void externalPEDecl(int entityName,
                           int publicId,
                           int systemId)
                    throws java.lang.Exception
callback for an external parameter entity declaration.
Parameters:
entityName - string pool index of the entity name
publicId - string pool index of the entity's public id.
systemId - string pool index of the entity's system id.
Throws:
java.lang.Exception -  

internalEntityDecl

public void internalEntityDecl(int entityName,
                               int entityValue)
                        throws java.lang.Exception
callback for internal general entity declaration.
Parameters:
entityName - string pool index of the entity name
entityValue - string pool index of the entity replacement text
Throws:
java.lang.Exception -  

externalEntityDecl

public void externalEntityDecl(int entityName,
                               int publicId,
                               int systemId)
                        throws java.lang.Exception
callback for external general entity declaration.
Parameters:
entityName - string pool index of the entity name
publicId - string pool index of the entity's public id.
systemId - string pool index of the entity's system id.
Throws:
java.lang.Exception -  

unparsedEntityDecl

public void unparsedEntityDecl(int entityName,
                               int publicId,
                               int systemId,
                               int notationName)
                        throws java.lang.Exception
callback for an unparsed entity declaration.
Parameters:
entityName - string pool index of the entity name
publicId - string pool index of the entity's public id.
systemId - string pool index of the entity's system id.
notationName - string pool index of the notation name.
Throws:
java.lang.Exception -  

notationDecl

public void notationDecl(int notationName,
                         int publicId,
                         int systemId)
                  throws java.lang.Exception
callback for a notation declaration.
Parameters:
notationName - string pool index of the notation name
publicId - string pool index of the notation's public id.
systemId - string pool index of the notation's system id.
Throws:
java.lang.Exception -  

commentInDTD

public void commentInDTD(int dataIndex)
                  throws java.lang.Exception
Callback for comment in DTD.
Parameters:
comment - the string pool index of the comment text
Throws:
java.lang.Exception -  

processingInstructionInDTD

public void processingInstructionInDTD(int targetIndex,
                                       int dataIndex)
                                throws java.lang.Exception
Callback for processing instruction in DTD.
Parameters:
target - the string pool index of the PI's target
data - the string pool index of the PI's data
Throws:
java.lang.Exception -  

startNamespaceDeclScope

public void startNamespaceDeclScope(int prefix,
                                    int uri)
                             throws java.lang.Exception
callback for the start of a namespace declaration scope.
Parameters:
prefix - string pool index of the namespace prefix being declared
uri - string pool index of the namespace uri begin bound
java.lang.Exception -  

endNamespaceDeclScope

public void endNamespaceDeclScope(int prefix)
                           throws java.lang.Exception
callback for the end a namespace declaration scope.
Parameters:
prefix - string pool index of the namespace prefix being declared
Throws:
java.lang.Exception -  

internalSubset

public void internalSubset(int internalSubset)
Supports DOM Level 2 internalSubset addition. Called when the internal subset is completely scanned.


Copyright © 1999 Apache XML Project. All Rights Reserved.