Class ReferenceAdapterV2<T extends org.eclipse.persistence.internal.jpa.rs.weaving.PersistenceWeavedRest>
- java.lang.Object
-
- jakarta.xml.bind.annotation.adapters.XmlAdapter<T,T>
-
- org.eclipse.persistence.jpa.rs.util.xmladapters.ReferenceAdapterV2<T>
-
- Type Parameters:
T
- entity class of this adapter
public class ReferenceAdapterV2<T extends org.eclipse.persistence.internal.jpa.rs.weaving.PersistenceWeavedRest> extends jakarta.xml.bind.annotation.adapters.XmlAdapter<T,T>
Reference adapter used in JPARS V2. Main purpose of this adapter is retrieving an entity by link when unmarshalling.- Author:
- Dmitry Kornilov
- Since:
- EclipseLink 2.6.0
-
-
Field Summary
Fields Modifier and Type Field Description protected PersistenceContext
context
-
Constructor Summary
Constructors Constructor Description ReferenceAdapterV2()
ReferenceAdapterV2(PersistenceContext context)
Instantiates a new reference adapter.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description T
marshal(T o)
Marshal just passes through.T
unmarshal(T o)
If 'canonical' or 'self' link is present loads entity from the database.
-
-
-
Field Detail
-
context
protected PersistenceContext context
-
-
Constructor Detail
-
ReferenceAdapterV2
public ReferenceAdapterV2()
-
ReferenceAdapterV2
public ReferenceAdapterV2(PersistenceContext context)
Instantiates a new reference adapter.- Parameters:
context
- persistent context (mandatory)
-
-