public class PCDataImpl extends AbstractPCData
PCData
implementation.NULL
Constructor and Description |
---|
PCDataImpl(Object oid,
ClassMetaData meta) |
PCDataImpl(Object oid,
ClassMetaData meta,
String name)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
clearData(int index) |
String |
getCache()
Get the name of the cache where this data is stored.
|
Object |
getData(int index)
Return the data stored in the given field index.
|
Object |
getId()
Return the id of this instance.
|
Object |
getImplData()
Returns the instance-level impl data, or null if none.
|
Object |
getImplData(int index) |
Object |
getIntermediate(int index) |
BitSet |
getLoaded()
Return the loaded field mask.
|
Class<?> |
getType()
Return the type of this instance.
|
Object |
getVersion()
Returns the current version object that this data was loaded from.
|
boolean |
isLoaded(int index)
Whether the given field index has stored data.
|
void |
load(OpenJPAStateManager sm,
BitSet fields,
FetchConfiguration fetch,
Object context)
Loads some or all of the marked fields from the cache into the
given state manager.
|
void |
load(OpenJPAStateManager sm,
FetchConfiguration fetch,
Object context)
Loads all fields that are currently stored in the cache
into the given state manager.
|
protected void |
loadField(OpenJPAStateManager sm,
FieldMetaData fmd,
FetchConfiguration fetch,
Object context)
Set field-level information into the given state manager.
|
protected void |
loadImplData(OpenJPAStateManager sm)
Set impl data information into the given state manager.
|
protected void |
loadImplData(OpenJPAStateManager sm,
FieldMetaData fmd)
Set field-level impl data into the given state manager.
|
protected void |
loadIntermediate(OpenJPAStateManager sm,
FieldMetaData fmd)
Set intermediate information for the given field into the state manager.
|
protected void |
loadVersion(OpenJPAStateManager sm)
Set version information into the given state manager.
|
AbstractPCData |
newEmbeddedPCData(OpenJPAStateManager sm)
Return a new
PCData implementation of the right type for
embedded instances. |
void |
setData(int index,
Object val) |
void |
setImplData(int index,
Object val) |
void |
setImplData(Object val)
Sets the stored instance-level impl data.
|
void |
setIntermediate(int index,
Object val) |
void |
setLoaded(int index,
boolean loaded) |
void |
setVersion(Object version)
Sets the current version object that this data was loaded from.
|
void |
store(OpenJPAStateManager sm)
Store all loaded fields of the state manager.
|
void |
store(OpenJPAStateManager sm,
BitSet fields)
Store the given fields from the state manager.
|
protected void |
storeField(OpenJPAStateManager sm,
FieldMetaData fmd)
Store field-level information from the given state manager.
|
protected void |
storeImplData(OpenJPAStateManager sm)
Store impl data from the given state manager.
|
protected void |
storeImplData(OpenJPAStateManager sm,
FieldMetaData fmd,
boolean fieldLoaded)
Store impl data for the given field.
|
protected void |
storeIntermediate(OpenJPAStateManager sm,
FieldMetaData fmd)
Store the intermediate field value for the given field.
|
protected void |
storeVersion(OpenJPAStateManager sm)
Store version information from the given state manager.
|
toData, toEmbeddedData, toEmbeddedField, toField, toNestedData, toNestedField, toNestedFields, toRelationData, toRelationField, toRelationFields
public PCDataImpl(Object oid, ClassMetaData meta)
public PCDataImpl(Object oid, ClassMetaData meta, String name)
public Object getId()
PCData
public Class<?> getType()
PCData
public BitSet getLoaded()
AbstractPCData
getLoaded
in class AbstractPCData
public Object getData(int index)
PCData
public void setData(int index, Object val)
public void clearData(int index)
public Object getImplData()
PCData
public void setImplData(Object val)
PCData
public Object getImplData(int index)
public void setImplData(int index, Object val)
public Object getIntermediate(int index)
public void setIntermediate(int index, Object val)
public boolean isLoaded(int index)
PCData
isLoaded
in interface PCData
isLoaded
in class AbstractPCData
public void setLoaded(int index, boolean loaded)
public Object getVersion()
PCData
public void setVersion(Object version)
PCData
public void load(OpenJPAStateManager sm, FetchConfiguration fetch, Object context)
PCData
sm
- the state manager to loadfetch
- the fetch configuration to use for loading related objectscontext
- current context informationpublic void load(OpenJPAStateManager sm, BitSet fields, FetchConfiguration fetch, Object context)
PCData
sm
- the state manager to loadfields
- the fields to load; clear the bits for the fields
that are successfully loadedfetch
- the fetch configuration to use for loading related objectscontext
- current context informationprotected void loadVersion(OpenJPAStateManager sm)
protected void loadImplData(OpenJPAStateManager sm)
protected void loadField(OpenJPAStateManager sm, FieldMetaData fmd, FetchConfiguration fetch, Object context)
protected void loadImplData(OpenJPAStateManager sm, FieldMetaData fmd)
protected void loadIntermediate(OpenJPAStateManager sm, FieldMetaData fmd)
public void store(OpenJPAStateManager sm)
PCData
public void store(OpenJPAStateManager sm, BitSet fields)
PCData
protected void storeVersion(OpenJPAStateManager sm)
protected void storeImplData(OpenJPAStateManager sm)
protected void storeField(OpenJPAStateManager sm, FieldMetaData fmd)
protected void storeIntermediate(OpenJPAStateManager sm, FieldMetaData fmd)
protected void storeImplData(OpenJPAStateManager sm, FieldMetaData fmd, boolean fieldLoaded)
public AbstractPCData newEmbeddedPCData(OpenJPAStateManager sm)
PCData
implementation of the right type for
embedded instances. Returns a PCDataImpl
by default.newEmbeddedPCData
in class AbstractPCData
Copyright © 2006–2020 Apache Software Foundation. All rights reserved.