Class SystemPropertiesDaoImpl
java.lang.Object
org.broadleafcommerce.common.cache.AbstractCacheMissAware<SystemProperty>
org.broadleafcommerce.common.config.dao.SystemPropertiesDaoImpl
- All Implemented Interfaces:
SystemPropertiesDao
@Repository("blSystemPropertiesDao")
public class SystemPropertiesDaoImpl
extends AbstractCacheMissAware<SystemProperty>
implements SystemPropertiesDao
This DAO enables access to manage system properties that can be stored in the database.
User: Kelly Tisdell
Date: 6/20/12
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected jakarta.persistence.EntityManager
protected EntityConfiguration
protected static final org.apache.commons.logging.Log
protected SystemPropertyDaoQueryExtensionManager
Fields inherited from class org.broadleafcommerce.common.cache.AbstractCacheMissAware
cacheManager, statisticsService
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
deleteSystemProperty
(SystemProperty systemProperty) protected org.apache.commons.logging.Log
To provide more accurate logging, this abstract cache should utilize a logger from its child implementation.protected SystemProperty
getNullObject
(Class<SystemProperty> responseClass) Retrieve a null representation of the cache item.protected String
getSite()
Reads a SystemProperty by its internal database idvoid
removeFromCache
(SystemProperty systemProperty) Removes the SystemProperty from the null-capable cache.saveSystemProperty
(SystemProperty systemProperty) Methods inherited from class org.broadleafcommerce.common.cache.AbstractCacheMissAware
buildKey, clearCache, getCache, getCachedObject, getObjectFromCache, removeItemFromCache
-
Field Details
-
LOG
protected static final org.apache.commons.logging.Log LOG -
em
protected jakarta.persistence.EntityManager em -
entityConfiguration
-
queryExtensionManager
-
-
Constructor Details
-
SystemPropertiesDaoImpl
public SystemPropertiesDaoImpl()
-
-
Method Details
-
readById
Description copied from interface:SystemPropertiesDao
Reads a SystemProperty by its internal database id- Specified by:
readById
in interfaceSystemPropertiesDao
- Returns:
- the
SystemProperty
-
saveSystemProperty
- Specified by:
saveSystemProperty
in interfaceSystemPropertiesDao
-
deleteSystemProperty
- Specified by:
deleteSystemProperty
in interfaceSystemPropertiesDao
-
readAllSystemProperties
- Specified by:
readAllSystemProperties
in interfaceSystemPropertiesDao
-
readSystemPropertyByName
- Specified by:
readSystemPropertyByName
in interfaceSystemPropertiesDao
-
removeFromCache
Description copied from interface:SystemPropertiesDao
Removes the SystemProperty from the null-capable cache.- Specified by:
removeFromCache
in interfaceSystemPropertiesDao
- Parameters:
systemProperty
- the property instance
-
createNewSystemProperty
- Specified by:
createNewSystemProperty
in interfaceSystemPropertiesDao
-
getLogger
protected org.apache.commons.logging.Log getLogger()Description copied from class:AbstractCacheMissAware
To provide more accurate logging, this abstract cache should utilize a logger from its child implementation.- Specified by:
getLogger
in classAbstractCacheMissAware<SystemProperty>
- Returns:
- a
Log
instance from the subclass of this abstract class
-
getSite
-
getNullObject
Description copied from class:AbstractCacheMissAware
Retrieve a null representation of the cache item. This representation is the same for all cache misses and is used as the object representation to store in the cache for a cache miss.- Overrides:
getNullObject
in classAbstractCacheMissAware<SystemProperty>
- Parameters:
responseClass
- the class representing the type of the cache item- Returns:
- the null representation for the cache item
-