Interface RefundEventItemService<P extends RefundEventItem>
- All Superinterfaces:
com.broadleafcommerce.data.tracking.core.service.CrudEntityService<P>
- All Known Implementing Classes:
DefaultRefundEventItemService
public interface RefundEventItemService<P extends RefundEventItem>
extends com.broadleafcommerce.data.tracking.core.service.CrudEntityService<P>
- Author:
- Jacob Mitash
-
Method Summary
Modifier and TypeMethodDescriptioncalculateRefundTotal(Collection<P> items) Calculates the total amount to refund for a collection of refund event items.calculateRefundTotal(P item) Calculates the total amount to refund for a single refund event item.default voidcalculateTax(P refundEventItem) Deprecated.voidcalculateTax(P refundEventItem, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Calculate and apply tax values for a refund event item based off of it's corresponding billing event item and refund amounts.default PDeprecated.UseCrudEntityService.create(Object, ContextInfo)insteadfindByBillingItemId(String itemId) Deprecated.UsereadByBillingEventItemId(String, ContextInfo)insteadfindByBillingItemIds(Set<String> itemIds) Deprecated.UsereadByBillingEventItemIds(Set, ContextInfo)insteadDeprecated.UseCrudEntityService.readByContextId(String, ContextInfo)insteadfindByRefundId(String refundEventId) Deprecated.UsereadByRefundEventId(String, ContextInfo)insteadreadByBillingEventItemId(String billingEventItemId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Finds all refund event items belonging to a billing item.readByBillingEventItemIds(Set<String> billingEventItemIds, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Finds all refund event items belonging to the billing items.readByRefundEventId(String refundEventId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Finds all refund event items belonging to a refund event.default PDeprecated.UseCrudEntityService.update(String, Object, ContextInfo)insteadMethods inherited from interface com.broadleafcommerce.data.tracking.core.service.CrudEntityService
create, createAll, createAllAllowingPartialSuccess, delete, readAll, readAll, readAll, readAllByContextId, readByContextId, replace, replaceAll, replaceAllAllowingPartialSuccess, update, updateAll, updateAllAllowingPartialSuccess, updateSort
-
Method Details
-
findById
Deprecated.UseCrudEntityService.readByContextId(String, ContextInfo)insteadFinds a refund event item by it's ID.- Parameters:
id- the refund event item's ID- Returns:
- the refund event item with the ID
-
create
Deprecated.UseCrudEntityService.create(Object, ContextInfo)insteadSaves a new refund event item.- Parameters:
refundEventItem- the refund event item to create- Returns:
- a saved version of the refund event item
-
update
Deprecated.UseCrudEntityService.update(String, Object, ContextInfo)insteadSaves changes to a refund event item.- Parameters:
refundEventItem- the refund event item to save changes for- Returns:
- a saved version of the refund event item
-
findByBillingItemId
Deprecated.UsereadByBillingEventItemId(String, ContextInfo)insteadFinds all refund event items belonging to a billing item. -
readByBillingEventItemId
Set<P> readByBillingEventItemId(String billingEventItemId, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Finds all refund event items belonging to a billing item. -
findByBillingItemIds
Deprecated.UsereadByBillingEventItemIds(Set, ContextInfo)insteadFinds all refund event items belonging to the billing items. -
readByBillingEventItemIds
Set<P> readByBillingEventItemIds(Set<String> billingEventItemIds, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Finds all refund event items belonging to the billing items.- Returns:
- refund event items belonging to the items
-
findByRefundId
Deprecated.UsereadByRefundEventId(String, ContextInfo)insteadFinds all refund event items belonging to a refund event. -
readByRefundEventId
Set<P> readByRefundEventId(String refundEventId, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Finds all refund event items belonging to a refund event.- Returns:
- refund event items belonging to the refund event
-
calculateTax
Deprecated.UsecalculateTax(RefundEventItem, ContextInfo)insteadCalculate and apply tax values for a refund event item based off of it's corresponding billing event item and refund amounts. -
calculateTax
void calculateTax(P refundEventItem, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Calculate and apply tax values for a refund event item based off of it's corresponding billing event item and refund amounts. -
calculateRefundTotal
Calculates the total amount to refund for a collection of refund event items. This is essentially the sum ofcalculateRefundTotal(RefundEventItem)for every item in the collection.- Parameters:
items- the items to calculate a refund total of- Returns:
- the total refund amount for the given items
-
calculateRefundTotal
Calculates the total amount to refund for a single refund event item.- Parameters:
item- the item to calculate the refund total of- Returns:
- the total refund amount for the given item
-
calculateTax(RefundEventItem, ContextInfo)instead