Class ReferenceAdapter<T extends org.eclipse.persistence.internal.weaving.PersistenceWeavedRest>
- java.lang.Object
-
- javax.xml.bind.annotation.adapters.XmlAdapter<java.lang.Object,java.lang.Object>
-
- org.eclipse.persistence.jpa.rs.util.xmladapters.ReferenceAdapter<T>
-
public class ReferenceAdapter<T extends org.eclipse.persistence.internal.weaving.PersistenceWeavedRest> extends XmlAdapter<java.lang.Object,java.lang.Object>
-
-
Constructor Summary
Constructors Constructor Description ReferenceAdapter()
Instantiates a new reference adapter.ReferenceAdapter(java.lang.String baseURI, PersistenceContext context)
Instantiates a new reference adapter.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.eclipse.persistence.internal.jpa.rs.metadata.model.Link
marshal(java.lang.Object o)
Convert a bound type to a value type.T
unmarshal(java.lang.Object object)
Convert a value type to a bound type.
-
-
-
Constructor Detail
-
ReferenceAdapter
public ReferenceAdapter()
Instantiates a new reference adapter.
-
ReferenceAdapter
public ReferenceAdapter(java.lang.String baseURI, PersistenceContext context)
Instantiates a new reference adapter.- Parameters:
baseURI
- the base uricontext
- the context
-
-
Method Detail
-
marshal
public org.eclipse.persistence.internal.jpa.rs.metadata.model.Link marshal(java.lang.Object o) throws java.lang.Exception
Description copied from class:XmlAdapter
Convert a bound type to a value type.- Specified by:
marshal
in classXmlAdapter<java.lang.Object,java.lang.Object>
- Parameters:
o
- The value to be convereted. Can be null.- Throws:
java.lang.Exception
- if there's an error during the conversion. The caller is responsible for reporting the error to the user throughValidationEventHandler
.
-
unmarshal
public T unmarshal(java.lang.Object object) throws java.lang.Exception
Description copied from class:XmlAdapter
Convert a value type to a bound type.- Specified by:
unmarshal
in classXmlAdapter<java.lang.Object,java.lang.Object>
- Parameters:
object
- The value to be converted. Can be null.- Throws:
java.lang.Exception
- if there's an error during the conversion. The caller is responsible for reporting the error to the user throughValidationEventHandler
.
-
-