Class DeferredContentHandler
- java.lang.Object
-
- org.eclipse.persistence.internal.oxm.record.deferred.DeferredContentHandler
-
- All Implemented Interfaces:
ExtendedContentHandler,org.xml.sax.ContentHandler,org.xml.sax.ext.LexicalHandler
- Direct Known Subclasses:
AnyMappingContentHandler,BinaryMappingContentHandler,CompositeMappingContentHandler,DescriptorNotFoundContentHandler
public abstract class DeferredContentHandler extends java.lang.Object implements ExtendedContentHandler, org.xml.sax.ext.LexicalHandler
Purpose: ContentHandler to store events until we know if we are dealing with a simple, complex or empty element.
Responsibilities:
- Store events until will know if the element is simple, complex or empty
- Return control to the original unmarshalRecord
-
-
Constructor Summary
Constructors Constructor Description DeferredContentHandler(UnmarshalRecord parentRecord)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected org.eclipse.persistence.internal.oxm.record.deferred.DeferredContentHandler.AttributeListbuildAttributeList(org.xml.sax.Attributes attrs)voidcharacters(char[] ch, int start, int length)voidcharacters(java.lang.CharSequence characters)voidcomment(char[] ch, int start, int length)voidendCDATA()voidendDocument()voidendDTD()voidendElement(java.lang.String uri, java.lang.String localName, java.lang.String qName)voidendEntity(java.lang.String name)voidendPrefixMapping(java.lang.String prefix)protected voidexecuteEvents(UnmarshalRecord unmarshalRecord)protected java.util.ListgetEvents()protected UnmarshalRecordgetParent()voidignorableWhitespace(char[] ch, int start, int length)protected abstract voidprocessComplexElement()protected abstract voidprocessEmptyElement()protected voidprocessEmptyElementWithAttributes()voidprocessingInstruction(java.lang.String target, java.lang.String data)protected abstract voidprocessSimpleElement()voidsetDocumentLocator(org.xml.sax.Locator locator)voidsetNil(boolean isNil)This method can be used to track that the current element is nilvoidskippedEntity(java.lang.String name)voidstartCDATA()voidstartDocument()voidstartDTD(java.lang.String name, java.lang.String publicId, java.lang.String systemId)voidstartElement(java.lang.String uri, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes atts)voidstartEntity(java.lang.String name)voidstartPrefixMapping(java.lang.String prefix, java.lang.String uri)
-
-
-
Constructor Detail
-
DeferredContentHandler
public DeferredContentHandler(UnmarshalRecord parentRecord)
-
-
Method Detail
-
setNil
public void setNil(boolean isNil)
Description copied from interface:ExtendedContentHandlerThis method can be used to track that the current element is nil- Specified by:
setNilin interfaceExtendedContentHandler
-
processEmptyElement
protected abstract void processEmptyElement() throws org.xml.sax.SAXException- Throws:
org.xml.sax.SAXException
-
processComplexElement
protected abstract void processComplexElement() throws org.xml.sax.SAXException- Throws:
org.xml.sax.SAXException
-
processSimpleElement
protected abstract void processSimpleElement() throws org.xml.sax.SAXException- Throws:
org.xml.sax.SAXException
-
processEmptyElementWithAttributes
protected void processEmptyElementWithAttributes() throws org.xml.sax.SAXException- Throws:
org.xml.sax.SAXException
-
executeEvents
protected void executeEvents(UnmarshalRecord unmarshalRecord) throws org.xml.sax.SAXException
- Throws:
org.xml.sax.SAXException
-
startPrefixMapping
public void startPrefixMapping(java.lang.String prefix, java.lang.String uri) throws org.xml.sax.SAXException- Specified by:
startPrefixMappingin interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
endPrefixMapping
public void endPrefixMapping(java.lang.String prefix) throws org.xml.sax.SAXException- Specified by:
endPrefixMappingin interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
startElement
public void startElement(java.lang.String uri, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes atts) throws org.xml.sax.SAXException- Specified by:
startElementin interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
buildAttributeList
protected org.eclipse.persistence.internal.oxm.record.deferred.DeferredContentHandler.AttributeList buildAttributeList(org.xml.sax.Attributes attrs) throws org.xml.sax.SAXException- Throws:
org.xml.sax.SAXException
-
endElement
public void endElement(java.lang.String uri, java.lang.String localName, java.lang.String qName) throws org.xml.sax.SAXException- Specified by:
endElementin interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
setDocumentLocator
public void setDocumentLocator(org.xml.sax.Locator locator)
- Specified by:
setDocumentLocatorin interfaceorg.xml.sax.ContentHandler
-
startDocument
public void startDocument() throws org.xml.sax.SAXException- Specified by:
startDocumentin interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
endDocument
public void endDocument() throws org.xml.sax.SAXException- Specified by:
endDocumentin interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
characters
public void characters(char[] ch, int start, int length) throws org.xml.sax.SAXException- Specified by:
charactersin interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
characters
public void characters(java.lang.CharSequence characters)
- Specified by:
charactersin interfaceExtendedContentHandler
-
ignorableWhitespace
public void ignorableWhitespace(char[] ch, int start, int length) throws org.xml.sax.SAXException- Specified by:
ignorableWhitespacein interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
processingInstruction
public void processingInstruction(java.lang.String target, java.lang.String data) throws org.xml.sax.SAXException- Specified by:
processingInstructionin interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
skippedEntity
public void skippedEntity(java.lang.String name) throws org.xml.sax.SAXException- Specified by:
skippedEntityin interfaceorg.xml.sax.ContentHandler- Throws:
org.xml.sax.SAXException
-
startDTD
public void startDTD(java.lang.String name, java.lang.String publicId, java.lang.String systemId) throws org.xml.sax.SAXException- Specified by:
startDTDin interfaceorg.xml.sax.ext.LexicalHandler- Throws:
org.xml.sax.SAXException
-
endDTD
public void endDTD() throws org.xml.sax.SAXException- Specified by:
endDTDin interfaceorg.xml.sax.ext.LexicalHandler- Throws:
org.xml.sax.SAXException
-
startEntity
public void startEntity(java.lang.String name) throws org.xml.sax.SAXException- Specified by:
startEntityin interfaceorg.xml.sax.ext.LexicalHandler- Throws:
org.xml.sax.SAXException
-
endEntity
public void endEntity(java.lang.String name) throws org.xml.sax.SAXException- Specified by:
endEntityin interfaceorg.xml.sax.ext.LexicalHandler- Throws:
org.xml.sax.SAXException
-
startCDATA
public void startCDATA() throws org.xml.sax.SAXException- Specified by:
startCDATAin interfaceorg.xml.sax.ext.LexicalHandler- Throws:
org.xml.sax.SAXException
-
endCDATA
public void endCDATA() throws org.xml.sax.SAXException- Specified by:
endCDATAin interfaceorg.xml.sax.ext.LexicalHandler- Throws:
org.xml.sax.SAXException
-
comment
public void comment(char[] ch, int start, int length) throws org.xml.sax.SAXException- Specified by:
commentin interfaceorg.xml.sax.ext.LexicalHandler- Throws:
org.xml.sax.SAXException
-
getParent
protected UnmarshalRecord getParent()
-
getEvents
protected java.util.List getEvents()
-
-