Class DefaultSubscriptionCommercePriceService
java.lang.Object
de.hybris.platform.commerceservices.price.impl.DefaultCommercePriceService
de.hybris.platform.subscriptionservices.price.impl.DefaultSubscriptionCommercePriceService
- All Implemented Interfaces:
CommercePriceService,SubscriptionCommercePriceService
public class DefaultSubscriptionCommercePriceService
extends DefaultCommercePriceService
implements SubscriptionCommercePriceService
Default implementation of
SubscriptionCommercePriceService.-
Nested Class Summary
Nested classes/interfaces inherited from class de.hybris.platform.commerceservices.price.impl.DefaultCommercePriceService
DefaultCommercePriceService.PriceInformationComparator -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected ExtendedPriceFactoryReturns the first recurring price of the givenSubscriptionPricePlanModel.Returns the last recurring price of the givenSubscriptionPricePlanModel.protected ModelServicegetOneTimeChargeEntryPlan(SubscriptionPricePlanModel pricePlan, BillingEventModel billingEvent) Returns the one time charge entry of the givenSubscriptionPricePlanModel.Search aSubscriptionPricePlanModelfor the givenentry's product.getSubscriptionPricePlanForProduct(ProductModel subscriptionProduct) Search aSubscriptionPricePlanModelfor the givensubscriptionProduct.voidsetModelService(ModelService modelService) Methods inherited from class de.hybris.platform.commerceservices.price.impl.DefaultCommercePriceService
fillAllVariantPrices, getAllVariantPrices, getFromPriceForProduct, getLowestVariantPrice, getPriceService, getWebPriceForProduct, setPriceServiceMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.hybris.platform.commerceservices.price.CommercePriceService
getFromPriceForProduct, getWebPriceForProduct
-
Constructor Details
-
DefaultSubscriptionCommercePriceService
public DefaultSubscriptionCommercePriceService()
-
-
Method Details
-
getSubscriptionPricePlanForEntry
@Nullable public SubscriptionPricePlanModel getSubscriptionPricePlanForEntry(AbstractOrderEntryModel entry) Description copied from interface:SubscriptionCommercePriceServiceSearch aSubscriptionPricePlanModelfor the givenentry's product.- Specified by:
getSubscriptionPricePlanForEntryin interfaceSubscriptionCommercePriceService- Parameters:
entry- theAbstractOrderEntryModel- Returns:
- the applicable
SubscriptionPricePlanModelor null
-
getSubscriptionPricePlanForProduct
@Nullable public SubscriptionPricePlanModel getSubscriptionPricePlanForProduct(@Nonnull ProductModel subscriptionProduct) Description copied from interface:SubscriptionCommercePriceServiceSearch aSubscriptionPricePlanModelfor the givensubscriptionProduct.- Specified by:
getSubscriptionPricePlanForProductin interfaceSubscriptionCommercePriceService- Parameters:
subscriptionProduct- theSubscriptionProductModel- Returns:
- the applicable
SubscriptionPricePlanModelor null
-
getFirstRecurringPriceFromPlan
@Nullable public RecurringChargeEntryModel getFirstRecurringPriceFromPlan(@Nullable SubscriptionPricePlanModel pricePlan) Description copied from interface:SubscriptionCommercePriceServiceReturns the first recurring price of the givenSubscriptionPricePlanModel. It is assumed that the recurring prices are sorted in a way so that the price increases as time goes by. Therefore, the returned recurring price is the lowest price. If price logic is different this function must be overridden.- Specified by:
getFirstRecurringPriceFromPlanin interfaceSubscriptionCommercePriceService- Parameters:
pricePlan-SubscriptionPricePlanModel- Returns:
- the first recurring price of the given
pricePlanor null
-
getLastRecurringPriceFromPlan
@Nullable public RecurringChargeEntryModel getLastRecurringPriceFromPlan(@Nullable SubscriptionPricePlanModel pricePlan) Description copied from interface:SubscriptionCommercePriceServiceReturns the last recurring price of the givenSubscriptionPricePlanModel. It is assumed that the recurring prices are sorted in a way so that the price increases as time goes by. Therefore, the returned recurring price is the highest price. If price logic is different this function must be overridden.- Specified by:
getLastRecurringPriceFromPlanin interfaceSubscriptionCommercePriceService- Parameters:
pricePlan-SubscriptionPricePlanModel- Returns:
- the last recurring price of the given
pricePlanor null
-
getCurrentPriceFactory
-
getModelService
-
setModelService
-
getOneTimeChargeEntryPlan
@Nullable public OneTimeChargeEntryModel getOneTimeChargeEntryPlan(@Nonnull SubscriptionPricePlanModel pricePlan, @Nonnull BillingEventModel billingEvent) Description copied from interface:SubscriptionCommercePriceServiceReturns the one time charge entry of the givenSubscriptionPricePlanModel.- Specified by:
getOneTimeChargeEntryPlanin interfaceSubscriptionCommercePriceService- Parameters:
pricePlan-SubscriptionPricePlanModelbillingEvent-BillingEventModel- Returns:
- the OneTimeChargeEntry
-