org.hibernate.envers.entities.mapper.relation
Class BasicCollectionMapper<T extends Collection>

java.lang.Object
  extended by org.hibernate.envers.entities.mapper.relation.AbstractCollectionMapper<T>
      extended by org.hibernate.envers.entities.mapper.relation.BasicCollectionMapper<T>
All Implemented Interfaces:
PropertyMapper
Direct Known Subclasses:
SortedSetCollectionMapper

public class BasicCollectionMapper<T extends Collection>
extends AbstractCollectionMapper<T>
implements PropertyMapper


Field Summary
protected  MiddleComponentData elementComponentData
           
 
Fields inherited from class org.hibernate.envers.entities.mapper.relation.AbstractCollectionMapper
collectionClass, commonCollectionMapperData
 
Constructor Summary
BasicCollectionMapper(CommonCollectionMapperData commonCollectionMapperData, Class<? extends T> collectionClass, Class<? extends T> proxyClass, MiddleComponentData elementComponentData)
           
 
Method Summary
protected  Initializor<T> getInitializor(AuditConfiguration verCfg, AuditReaderImplementor versionsReader, Object primaryKey, Number revision)
           
protected  Collection getNewCollectionContent(PersistentCollection newCollection)
           
protected  Collection getOldCollectionContent(Serializable oldCollection)
           
protected  void mapToMapFromObject(Map<String,Object> data, Object changed)
          Maps the changed collection element to the given map.
 
Methods inherited from class org.hibernate.envers.entities.mapper.relation.AbstractCollectionMapper
mapCollectionChanges, mapModifiedFlagsToMapForCollectionChange, mapModifiedFlagsToMapFromEntity, mapToEntityFromMap, mapToMapFromEntity
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.hibernate.envers.entities.mapper.PropertyMapper
mapCollectionChanges, mapModifiedFlagsToMapForCollectionChange, mapModifiedFlagsToMapFromEntity, mapToEntityFromMap, mapToMapFromEntity
 

Field Detail

elementComponentData

protected final MiddleComponentData elementComponentData
Constructor Detail

BasicCollectionMapper

public BasicCollectionMapper(CommonCollectionMapperData commonCollectionMapperData,
                             Class<? extends T> collectionClass,
                             Class<? extends T> proxyClass,
                             MiddleComponentData elementComponentData)
Method Detail

getInitializor

protected Initializor<T> getInitializor(AuditConfiguration verCfg,
                                        AuditReaderImplementor versionsReader,
                                        Object primaryKey,
                                        Number revision)
Specified by:
getInitializor in class AbstractCollectionMapper<T extends Collection>

getNewCollectionContent

protected Collection getNewCollectionContent(PersistentCollection newCollection)
Specified by:
getNewCollectionContent in class AbstractCollectionMapper<T extends Collection>

getOldCollectionContent

protected Collection getOldCollectionContent(Serializable oldCollection)
Specified by:
getOldCollectionContent in class AbstractCollectionMapper<T extends Collection>

mapToMapFromObject

protected void mapToMapFromObject(Map<String,Object> data,
                                  Object changed)
Description copied from class: AbstractCollectionMapper
Maps the changed collection element to the given map.

Specified by:
mapToMapFromObject in class AbstractCollectionMapper<T extends Collection>
Parameters:
data - Where to map the data.
changed - The changed collection element to map.


Copyright © 2001-2012 Red Hat, Inc. All Rights Reserved.