|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.hibernate.envers.entities.mapper.relation.component.MiddleMapKeyIdComponentMapper
public final class MiddleMapKeyIdComponentMapper
A component mapper for the @MapKey mapping: the value of the map's key is the id of the entity. This
doesn't have an effect on the data stored in the versions tables, so mapToMapFromObject
is
empty.
Constructor Summary | |
---|---|
MiddleMapKeyIdComponentMapper(AuditEntitiesConfiguration verEntCfg,
IdMapper relatedIdMapper)
|
Method Summary | |
---|---|
void |
addMiddleEqualToQuery(Parameters parameters,
String prefix1,
String prefix2)
Adds query statements, which contains restrictions, which express the property that part of the middle entity with alias prefix1, is equal to part of the middle entity with alias prefix2 (the entity is the same). |
void |
mapToMapFromObject(Map<String,Object> data,
Object obj)
Maps from an object to the object's map representation (for an entity - only its id). |
Object |
mapToObjectFromFullMap(EntityInstantiator entityInstantiator,
Map<String,Object> data,
Object dataObject,
Number revision)
Maps from full object data, contained in the given map (or object representation of the map, if available), to an object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MiddleMapKeyIdComponentMapper(AuditEntitiesConfiguration verEntCfg, IdMapper relatedIdMapper)
Method Detail |
---|
public Object mapToObjectFromFullMap(EntityInstantiator entityInstantiator, Map<String,Object> data, Object dataObject, Number revision)
MiddleComponentMapper
mapToObjectFromFullMap
in interface MiddleComponentMapper
entityInstantiator
- An entity instatiator bound with an open versions reader.data
- Full object data.dataObject
- An optional object representation of the data.revision
- Revision at which the data is read.
public void mapToMapFromObject(Map<String,Object> data, Object obj)
MiddleComponentMapper
mapToMapFromObject
in interface MiddleComponentMapper
data
- Map to which data should be added.obj
- Object to map from.public void addMiddleEqualToQuery(Parameters parameters, String prefix1, String prefix2)
MiddleComponentMapper
addMiddleEqualToQuery
in interface MiddleComponentMapper
parameters
- Parameters, to which to add the statements.prefix1
- First alias of the entity + prefix to add to the properties.prefix2
- Second alias of the entity + prefix to add to the properties.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |