BasePersistenceService

public abstract class BasePersistenceService

The BasePersistenceService class provides utility methods for communication with the database for HistoryServiceImpl and TrashServiceImpl. It allows to create and retrieve instances, load proper classes and parse values.

Methods

convertToIdsCollection

protected Collection<Long> convertToIdsCollection(Collection collection)

create

protected <T> Object create(Class<T> clazz, Object instance, Object existingRecord)

getBundleContext

protected BundleContext getBundleContext()

getCurrentSchemaVersion

protected Long getCurrentSchemaVersion(String className)

getInstanceId

protected Long getInstanceId(Object instance)

getPersistenceManagerFactory

protected PersistenceManagerFactory getPersistenceManagerFactory()

getRelConverter

protected RelationshipConverter getRelConverter()

setAppContext

public void setAppContext(ApplicationContext appContext)

setBundleContext

public void setBundleContext(BundleContext bundleContext)

setPersistenceManagerFactory

public void setPersistenceManagerFactory(PersistenceManagerFactory persistenceManagerFactory)