Module org.eclipse.persistence.core
Class DOMUnmarshaller
- java.lang.Object
-
- org.eclipse.persistence.internal.oxm.record.DOMUnmarshaller
-
- All Implemented Interfaces:
PlatformUnmarshaller
public class DOMUnmarshaller extends Object implements PlatformUnmarshaller
INTERNAL:Purpose:Provide an implementation of PlatformUnmarshaller that makes use of the DOM unmarshal code. Used by the DOMPlatform
Responsibilities:
- Implement the required unmarshal methods from platform unmarshaller
- Perform xml-to-object conversions
- Author:
- bdoughan
- See Also:
DOMPlatform
-
-
Constructor Summary
Constructors Constructor Description DOMUnmarshaller(XMLUnmarshaller xmlUnmarshaller, Map<String,Boolean> parserFeatures)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EntityResolvergetEntityResolver()ErrorHandlergetErrorHandler()SchemagetSchema()intgetValidationMode()booleanisResultAlwaysXMLRoot()booleanisSecureProcessingDisabled()voidmediaTypeChanged()voidsetDisableSecureProcessing(boolean disableSecureProcessing)voidsetEntityResolver(EntityResolver entityResolver)voidsetErrorHandler(ErrorHandler errorHandler)voidsetResultAlwaysXMLRoot(boolean alwaysReturnRoot)voidsetSchema(Schema schema)voidsetSchemas(Object[] schemas)voidsetValidationMode(int validationMode)voidsetWhitespacePreserving(boolean isWhitespacePreserving)Objectunmarshal(File file)Objectunmarshal(File file, Class<?> clazz)Objectunmarshal(InputStream inputStream)Objectunmarshal(InputStream inputStream, Class<?> clazz)Objectunmarshal(Reader reader)Objectunmarshal(Reader reader, Class<?> clazz)Objectunmarshal(URL url)Objectunmarshal(URL url, Class<?> clazz)Objectunmarshal(Source source)Objectunmarshal(Source source, Class<?> clazz)Objectunmarshal(Node node)Objectunmarshal(Node node, Class<?> clazz)Objectunmarshal(InputSource inputSource)Objectunmarshal(InputSource inputSource, Class<?> clazz)Objectunmarshal(XMLReader xmlReader, InputSource inputSource)Objectunmarshal(XMLReader xmlReader, InputSource inputSource, Class<?> clazz)ObjectxmlToObject(DOMRecord xmlRecord)INTERNAL: Find the Descriptor corresponding to the context node of the XMLRecord, and then convert the XMLRecord to an instance of the corresponding object.ObjectxmlToObject(DOMRecord xmlRow, Class<?> referenceClass)INTERNAL: Convert the Oracle XMLDocument to the reference-class.
-
-
-
Constructor Detail
-
DOMUnmarshaller
public DOMUnmarshaller(XMLUnmarshaller xmlUnmarshaller, Map<String,Boolean> parserFeatures)
-
-
Method Detail
-
getEntityResolver
public EntityResolver getEntityResolver()
- Specified by:
getEntityResolverin interfacePlatformUnmarshaller
-
setEntityResolver
public void setEntityResolver(EntityResolver entityResolver)
- Specified by:
setEntityResolverin interfacePlatformUnmarshaller
-
getErrorHandler
public ErrorHandler getErrorHandler()
- Specified by:
getErrorHandlerin interfacePlatformUnmarshaller
-
setErrorHandler
public void setErrorHandler(ErrorHandler errorHandler)
- Specified by:
setErrorHandlerin interfacePlatformUnmarshaller
-
getValidationMode
public int getValidationMode()
- Specified by:
getValidationModein interfacePlatformUnmarshaller
-
setValidationMode
public void setValidationMode(int validationMode)
- Specified by:
setValidationModein interfacePlatformUnmarshaller
-
setWhitespacePreserving
public void setWhitespacePreserving(boolean isWhitespacePreserving)
- Specified by:
setWhitespacePreservingin interfacePlatformUnmarshaller
-
setSchemas
public void setSchemas(Object[] schemas)
- Specified by:
setSchemasin interfacePlatformUnmarshaller
-
setSchema
public void setSchema(Schema schema)
- Specified by:
setSchemain interfacePlatformUnmarshaller
-
getSchema
public Schema getSchema()
- Specified by:
getSchemain interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(File file)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(File file, Class<?> clazz)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(InputStream inputStream)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(InputStream inputStream, Class<?> clazz)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(InputSource inputSource)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(InputSource inputSource, Class<?> clazz)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(Node node)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(Node node, Class<?> clazz)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(Reader reader)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(Reader reader, Class<?> clazz)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(Source source)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(Source source, Class<?> clazz)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(URL url)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(URL url, Class<?> clazz)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(XMLReader xmlReader, InputSource inputSource)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
unmarshal
public Object unmarshal(XMLReader xmlReader, InputSource inputSource, Class<?> clazz)
- Specified by:
unmarshalin interfacePlatformUnmarshaller
-
xmlToObject
public Object xmlToObject(DOMRecord xmlRecord) throws XMLMarshalException
INTERNAL: Find the Descriptor corresponding to the context node of the XMLRecord, and then convert the XMLRecord to an instance of the corresponding object.- Parameters:
xmlRecord- The XMLRecord to unmarshal from- Returns:
- the object which resulted from unmarshalling the given XMLRecord
- Throws:
XMLMarshalException- if an error occurred during unmarshalling
-
xmlToObject
public Object xmlToObject(DOMRecord xmlRow, Class<?> referenceClass) throws XMLMarshalException
INTERNAL: Convert the Oracle XMLDocument to the reference-class.- Throws:
XMLMarshalException
-
isResultAlwaysXMLRoot
public boolean isResultAlwaysXMLRoot()
- Specified by:
isResultAlwaysXMLRootin interfacePlatformUnmarshaller
-
setResultAlwaysXMLRoot
public void setResultAlwaysXMLRoot(boolean alwaysReturnRoot)
- Specified by:
setResultAlwaysXMLRootin interfacePlatformUnmarshaller
-
mediaTypeChanged
public void mediaTypeChanged()
- Specified by:
mediaTypeChangedin interfacePlatformUnmarshaller
-
isSecureProcessingDisabled
public final boolean isSecureProcessingDisabled()
- Specified by:
isSecureProcessingDisabledin interfacePlatformUnmarshaller
-
setDisableSecureProcessing
public final void setDisableSecureProcessing(boolean disableSecureProcessing)
- Specified by:
setDisableSecureProcessingin interfacePlatformUnmarshaller
-
-