public abstract class AbstractPersistenceManagerAware extends AbstractWorkflowSupport implements PersistenceManagerAware
Modifier and Type | Field and Description |
---|---|
protected SandBoxHelperImpl |
sandBoxHelper |
Constructor and Description |
---|
AbstractPersistenceManagerAware() |
Modifier and Type | Method and Description |
---|---|
Class<?> |
getCeilingImpl(org.broadleafcommerce.openadmin.dto.Entity entity)
Retrieve the class representing the top of the inheritance hierarchy for the Entity instance.
|
Class<?> |
getCeilingImpl(String className)
Retrieve the class representing the top of the inheritance hierarchy for the entity class.
|
org.broadleafcommerce.openadmin.server.service.persistence.module.FieldManager |
getFieldManager()
Retrieve the currently active FieldManager.
|
Serializable |
getIdentifier(Object temp)
Retrieve the primary key value for the entity class instance.
|
String |
getIdProperty(Class<?> type)
Retrieve the primary key property for the passed in entity type.
|
org.hibernate.type.Type |
getIdType(Class<?> type)
Retrieve the
Type for the passed in class. |
org.broadleafcommerce.common.sandbox.SandBoxHelper.OriginalIdResponse |
getOriginalId(Class<?> type,
Long id)
Return the original id for the requested id.
|
org.broadleafcommerce.openadmin.server.service.persistence.PersistenceManager |
getPersistenceManager()
Retrieve the currently active PersistenceManager.
|
Long |
getProdSandBoxVersionId(Class<?> type,
Long id) |
org.broadleafcommerce.common.sandbox.SandBoxHelper.OriginalIdResponse |
getProductionOriginalId(Class<?> type,
Long id)
Return the original id for the requested id as if this was a production request.
|
Long |
getSandBoxVersionId(Class<?> type,
Long id)
Retrieve the primary key value of the sandbox version (clone) for the passed in type and id.
|
<T> T |
load(Class<T> entityClass,
Object id)
Load an entity instance
|
List<Long> |
mergeCloneIds(Class<?> type,
Long... originalIds)
Retrieve a list of values that includes the the original ids passed in and any
sandbox versions of those ids, if available.
|
getGroupNameGeneralization
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getGroupNameGeneralization
protected SandBoxHelperImpl sandBoxHelper
public org.broadleafcommerce.openadmin.server.service.persistence.PersistenceManager getPersistenceManager()
PersistenceManagerAware
getPersistenceManager
in interface PersistenceManagerAware
public org.broadleafcommerce.openadmin.server.service.persistence.module.FieldManager getFieldManager()
PersistenceManagerAware
getFieldManager
in interface PersistenceManagerAware
public String getIdProperty(Class<?> type)
PersistenceManagerAware
getIdProperty
in interface PersistenceManagerAware
type
- the entity typepublic org.hibernate.type.Type getIdType(Class<?> type)
PersistenceManagerAware
Type
for the passed in class.getIdType
in interface PersistenceManagerAware
type
- the class to testpublic <T> T load(Class<T> entityClass, Object id)
PersistenceManagerAware
load
in interface PersistenceManagerAware
T
- the entity typeentityClass
- the entity typeid
- the entity primary key valuepublic Long getSandBoxVersionId(Class<?> type, Long id)
PersistenceManagerAware
getSandBoxVersionId
in interface PersistenceManagerAware
type
- the entity typeid
- the entity primary key valuepublic Long getProdSandBoxVersionId(Class<?> type, Long id)
getProdSandBoxVersionId
in interface PersistenceManagerAware
public org.broadleafcommerce.common.sandbox.SandBoxHelper.OriginalIdResponse getOriginalId(Class<?> type, Long id)
PersistenceManagerAware
getOriginalId
in interface PersistenceManagerAware
type
- the type of the entity in questionid
- the id to checkpublic org.broadleafcommerce.common.sandbox.SandBoxHelper.OriginalIdResponse getProductionOriginalId(Class<?> type, Long id)
PersistenceManagerAware
getProductionOriginalId
in interface PersistenceManagerAware
public List<Long> mergeCloneIds(Class<?> type, Long... originalIds)
PersistenceManagerAware
mergeCloneIds
in interface PersistenceManagerAware
type
- the type of the entity in questionoriginalIds
- one or more ids values for which sandbox versions should be includedpublic Class<?> getCeilingImpl(org.broadleafcommerce.openadmin.dto.Entity entity)
PersistenceManagerAware
getCeilingImpl
in interface PersistenceManagerAware
entity
- the Entity instancepublic Class<?> getCeilingImpl(String className)
PersistenceManagerAware
getCeilingImpl
in interface PersistenceManagerAware
className
- the name of the entity classpublic Serializable getIdentifier(Object temp)
PersistenceManagerAware
getIdentifier
in interface PersistenceManagerAware
temp
- the entity class instanceCopyright © 2019. All rights reserved.