## org.biojava.bio.seq.io.filterxml
Class XMLAnnotationTypeHandler

    java.lang.Object
      org.biojava.utils.stax.StAXContentHandlerBase
          org.biojava.bio.seq.io.filterxml.XMLAnnotationTypeHandler

All Implemented Interfaces:
  StAXContentHandler

    public class XMLAnnotationTypeHandler

extends StAXContentHandlerBase

StAX handler for parsing AnnotationTypes in FilterXML documents. Mainly used internally by XMLFilterHandler.

Since:
  1.3
Author:
  Thomas Down

Nested Class Summary
`static interface` `XMLAnnotationTypeHandler.CollectionConstraintHandler` Handler for an individual `CollectionConstraint` in an AnnotationType.
`static interface` `XMLAnnotationTypeHandler.CollectionConstraintHandlerFactory` Handler Factory for a `CollectionConstraint` in an AnnotationType.
`static interface` `XMLAnnotationTypeHandler.PropertyConstraintHandler` Handler for an individual `PropertyConstraint` in an AnnotationType.
`static interface` `XMLAnnotationTypeHandler.PropertyConstraintHandlerFactory` Handler Factory for a `PropertyConstraint` in an AnnotationType.

Constructor Summary
`XMLAnnotationTypeHandler()` Construct a new XMLAnnotationTypeHandler which can parse the builtin PropertyConstraints.

Method Summary
`void` `endElement(String nsURI, String localName, String qName, StAXContentHandler delegate)`
`AnnotationType` `getAnnotationType()` Return the AnnotationType built by this handler
`void` `registerCollectionHandlerFactory(String nsURI, String localName, XMLAnnotationTypeHandler.CollectionConstraintHandlerFactory factory)` Register a factory used to create handlers for the specified tag in an XML AnnotationType
`void` `registerPropertyHandlerFactory(String nsURI, String localName, XMLAnnotationTypeHandler.PropertyConstraintHandlerFactory factory)` Register a factory used to create handlers for the specified tag in an XML AnnotationType
`void` `startElement(String nsURI, String localName, String qName, Attributes attrs, DelegationManager dm)`

Methods inherited from class org.biojava.utils.stax.StAXContentHandlerBase
`characters, endPrefixMapping, endTree, ignorableWhitespace, processingInstruction, setDocumentLocator, skippedEntity, startPrefixMapping, startTree`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### XMLAnnotationTypeHandler

    public XMLAnnotationTypeHandler()

  Construct a new XMLAnnotationTypeHandler which can parse the builtin PropertyConstraints.

Method Detail

### getAnnotationType

    public AnnotationType getAnnotationType()

  Return the AnnotationType built by this handler

### registerPropertyHandlerFactory

    public void registerPropertyHandlerFactory(String nsURI,
                                               String localName,
                                               XMLAnnotationTypeHandler.PropertyConstraintHandlerFactory factory)

  Register a factory used to create handlers for the specified tag in an XML AnnotationType

### registerCollectionHandlerFactory

    public void registerCollectionHandlerFactory(String nsURI,
                                                 String localName,
                                                 XMLAnnotationTypeHandler.CollectionConstraintHandlerFactory factory)

  Register a factory used to create handlers for the specified tag in an XML AnnotationType

### startElement

    public void startElement(String nsURI,
                             String localName,
                             String qName,
                             Attributes attrs,
                             DelegationManager dm)
                      throws SAXException

  Specified by:
    `startElement` in interface `StAXContentHandler`
  Overrides:
    `startElement` in class `StAXContentHandlerBase`
  Throws:
    `SAXException`

### endElement

    public void endElement(String nsURI,
                           String localName,
                           String qName,
                           StAXContentHandler delegate)
                    throws SAXException

  Specified by:
    `endElement` in interface `StAXContentHandler`
  Overrides:
    `endElement` in class `StAXContentHandlerBase`
  Throws:
    `SAXException`