Interface CustomizedPriceDataUsageDetailRepository<D extends com.broadleafcommerce.data.tracking.core.Trackable>
- All Known Subinterfaces:
 JpaPriceDataUsageDetailRepository<D>,PriceDataUsageDetailRepository<D>
- All Known Implementing Classes:
 JpaCustomizedPriceDataUsageDetailRepository
public interface CustomizedPriceDataUsageDetailRepository<D extends com.broadleafcommerce.data.tracking.core.Trackable>
Custom repository methods for 
PriceDataUsageDetail- Author:
 - karanjariwala
 
- 
Method Summary
Modifier and TypeMethodDescriptionvoidarchiveAllByIds(Collection<String> priceDataUsageDetailIds, String archivalReason, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Archive multiplePriceDataUsageDetailsby ids.intdeletePriceDataUsageDetailsOlderThan(Instant dateBefore, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Deletes allPriceDataUsageDetailswhosePriceDataUsageDetail.getUsageDate()is older thandateBefore.org.springframework.data.domain.Page<D>findAllByRevertibleAndUsageDateBefore(Instant usageDateBefore, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Fetches a page ofPriceDataUsageDetailthat are "revertible"(revertible=true) and before the specified datevoidmarkRevertibleAllByIds(Collection<String> priceDataUsageDetailIds, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) voidupdateRevertibleByReferenceId(String transactionReferenceType, String transactionReferenceId, Boolean revertible, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)  
- 
Method Details
- 
findAllByRevertibleAndUsageDateBefore
@Policy(operationTypes=READ) org.springframework.data.domain.Page<D> findAllByRevertibleAndUsageDateBefore(Instant usageDateBefore, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Fetches a page ofPriceDataUsageDetailthat are "revertible"(revertible=true) and before the specified date- Parameters:
 usageDateBefore- - the date(instant) before usageDatepage- - page infocontextInfo- - the context info- Returns:
 - the page of 
PriceDataUsageDetail 
 - 
archiveAllByIds
@Policy(operationTypes=DELETE) void archiveAllByIds(Collection<String> priceDataUsageDetailIds, String archivalReason, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Archive multiplePriceDataUsageDetailsby ids.- Parameters:
 priceDataUsageDetailIds- the ids of priceDataUsageDetail to archivalarchivalReason- the reason for archivalcontextInfo- the context info- See Also:
 
 - 
updateRevertibleByReferenceId
 - 
markRevertibleAllByIds
@Policy(operationTypes=UPDATE) void markRevertibleAllByIds(Collection<String> priceDataUsageDetailIds, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)  - 
deletePriceDataUsageDetailsOlderThan
@Policy(operationTypes=DELETE) int deletePriceDataUsageDetailsOlderThan(Instant dateBefore, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Deletes allPriceDataUsageDetailswhosePriceDataUsageDetail.getUsageDate()is older thandateBefore.Used for cleanup of obsolete data
- Parameters:
 dateBefore- the time instant before which the records are to be deleted/purgedcontextInfo- the context info- Returns:
 - the number of records deleted
 
 
 -