Class DefaultCartFieldMappingService<P extends CartFieldMapping>
java.lang.Object
com.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService<P>
com.broadleafcommerce.data.tracking.core.service.BaseRsqlCrudEntityService<P>
com.broadleafcommerce.catalog.service.DefaultCartFieldMappingService<P>
- All Implemented Interfaces:
CartFieldMappingService<P>
,com.broadleafcommerce.data.tracking.core.service.CrudEntityService<P>
,com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityService<P>
public class DefaultCartFieldMappingService<P extends CartFieldMapping>
extends com.broadleafcommerce.data.tracking.core.service.BaseRsqlCrudEntityService<P>
implements CartFieldMappingService<P>
- Author:
- Jon Fleschler (jfleschler)
-
Field Summary
-
Constructor Summary
ConstructorDescriptionDefaultCartFieldMappingService
(CartFieldMappingRepository<com.broadleafcommerce.data.tracking.core.Trackable> repository, com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityHelper helper, com.broadleafcommerce.common.extension.cache.CacheStateManager cacheStateManager) -
Method Summary
Modifier and TypeMethodDescriptionprotected com.broadleafcommerce.common.extension.cache.key.ContextKeyGen
protected com.broadleafcommerce.common.extension.cache.CacheStateManager
protected CartFieldMappingRepository<com.broadleafcommerce.data.tracking.core.Trackable>
readAll
(com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Retrieves of all theCartItemProductMappings
.readByAttributeName
(String attributeName, com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Retrieve aCartFieldMapping
with the requested attribute name.void
setCacheByApplicationIdKeyGen
(com.broadleafcommerce.common.extension.cache.key.ContextKeyGen cacheByApplicationIdKeyGen) Methods inherited from class com.broadleafcommerce.data.tracking.core.service.BaseRsqlCrudEntityService
getRsqlHelper, readAll, readAll, readAll, readAll
Methods inherited from class com.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService
convertFromPersistentDomain, convertToPersistentDomain, create, createAll, createAllAllowingPartialSuccess, delete, getHelper, getSortPositionStrategy, readAll, readAll, readAllByContextId, readByContextId, replace, replaceAll, replaceAllAllowingPartialSuccess, setSortPositionStrategy, update, updateAll, updateAllAllowingPartialSuccess, updateSort
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.broadleafcommerce.data.tracking.core.service.CrudEntityService
create, createAll, createAllAllowingPartialSuccess, delete, readAll, readAll, readAllByContextId, readByContextId, replace, replaceAll, replaceAllAllowingPartialSuccess, update, updateAll, updateAllAllowingPartialSuccess, updateSort
Methods inherited from interface com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityService
readAll, readAll, readAll, readAll
-
Field Details
-
CACHE_BY_APPLICATION_ID
- See Also:
-
-
Constructor Details
-
DefaultCartFieldMappingService
public DefaultCartFieldMappingService(CartFieldMappingRepository<com.broadleafcommerce.data.tracking.core.Trackable> repository, com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityHelper helper, @Nullable com.broadleafcommerce.common.extension.cache.CacheStateManager cacheStateManager)
-
-
Method Details
-
readAll
public List<P> readAll(@Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Description copied from interface:CartFieldMappingService
Retrieves of all theCartItemProductMappings
.- Specified by:
readAll
in interfaceCartFieldMappingService<P extends CartFieldMapping>
- Specified by:
readAll
in interfacecom.broadleafcommerce.data.tracking.core.service.CrudEntityService<P extends CartFieldMapping>
- Overrides:
readAll
in classcom.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService<P extends CartFieldMapping>
- Parameters:
context
- the current context to look in- Returns:
- All the
CartItemProductMappings
.
-
readByAttributeName
@NonNull public Optional<P> readByAttributeName(@NonNull String attributeName, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Description copied from interface:CartFieldMappingService
Retrieve aCartFieldMapping
with the requested attribute name.- Specified by:
readByAttributeName
in interfaceCartFieldMappingService<P extends CartFieldMapping>
- Parameters:
attributeName
- the attribute name to matchcontext
- the current context to look in- Returns:
- a
CartFieldMapping
.
-
getRepository
@NonNull protected CartFieldMappingRepository<com.broadleafcommerce.data.tracking.core.Trackable> getRepository()- Overrides:
getRepository
in classcom.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService<P extends CartFieldMapping>
-
getCacheStateManager
@Nullable protected com.broadleafcommerce.common.extension.cache.CacheStateManager getCacheStateManager() -
setCacheByApplicationIdKeyGen
@Autowired @Qualifier("catalogCacheByApplicationId") public void setCacheByApplicationIdKeyGen(@Nullable com.broadleafcommerce.common.extension.cache.key.ContextKeyGen cacheByApplicationIdKeyGen) - See Also:
-
getCacheByApplicationIdKeyGen
@Nullable protected com.broadleafcommerce.common.extension.cache.key.ContextKeyGen getCacheByApplicationIdKeyGen()- See Also:
-