Class DefaultTravelCommercePriceService
java.lang.Object
de.hybris.platform.commerceservices.price.impl.DefaultCommercePriceService
de.hybris.platform.travelservices.price.impl.DefaultTravelCommercePriceService
- All Implemented Interfaces:
de.hybris.platform.commerceservices.price.CommercePriceService,TravelCommercePriceService
public class DefaultTravelCommercePriceService
extends de.hybris.platform.commerceservices.price.impl.DefaultCommercePriceService
implements TravelCommercePriceService
Default implementation of
TravelCommercePriceService-
Nested Class Summary
Nested classes/interfaces inherited from class de.hybris.platform.commerceservices.price.impl.DefaultCommercePriceService
de.hybris.platform.commerceservices.price.impl.DefaultCommercePriceService.PriceInformationComparator -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddPropertyPriceLevelToCartEntry(PriceLevel priceLevel, String productCode, int entryNo) Method to add price level property to cart entryprotected de.hybris.platform.order.CartServiceGets cart service.protected TravelPriceFactoryprotected de.hybris.platform.servicelayer.model.ModelServiceGets model service.de.hybris.platform.jalo.order.price.PriceInformationgetPriceInformation(ProductModel product, String searchKey, String searchValue) This method gets the price information for product code, search key and search value.getPriceLevelInfo(String productCode, List<String> transportOfferings, String routeCode, boolean isMultiSectorRoute) Method to find the price level info.getPriceLevelInfoByHierarchy(ProductModel product, String transportOfferingCode, String routeCode) Method to get the price level and value for product code, search key and search value.getPriceLevelInfoForAncillary(ProductModel productModel, String transportOfferingCode, String routeCode) Method to return price level info as a map, with price level as key and code as value.getPriceLevelInfoForFareProduct(ProductModel productModel, List<String> transportOfferings, String routeCode, boolean isMultiSectorRoute) Method to return price level info as a map, with price level as key and code as value.protected de.hybris.platform.product.ProductServiceList<de.hybris.platform.jalo.order.price.TaxInformation>getProductTaxInformations(ProductModel product) Method to retrieve taxes for the productde.hybris.platform.jalo.order.price.PriceInformationgetProductWebPrice(ProductModel product, Map<String, String> searchCriteria) Method to retrieve price for the product and travel specific search criteriaprotected de.hybris.platform.servicelayer.session.SessionServiceGets session service.protected de.hybris.platform.servicelayer.time.TimeServiceGets time service.protected TransportFacilityServiceGets transport facility service.protected TransportOfferingServiceGets transport offering service.protected TravelCommerceCartServiceGets travel commerce cart service.protected TravellerServiceGets traveller service.protected TravelPDTRowDaoisNetPricedProduct(ProductModel product) Return true if the product is net priced, false otherwisebooleanisPriceInformationAvailable(ProductModel product, String searchKey, String searchValue) Method to check if the price information is available for the given search criteriavoidsetCartService(de.hybris.platform.order.CartService cartService) Sets cart service.voidsetModelService(de.hybris.platform.servicelayer.model.ModelService modelService) Sets model service.voidsetOfferGroupToOriginDestinationMapping(Map<String, String> offerGroupToOriginDestinationMapping) voidsetPriceAndTaxSearchCriteriaInContext(PriceLevel priceLevel, List<String> transportOfferingCodes, String passengerType) Method to set price and tax search criteria in session context These values will be used to retrieve prices during cart calculation when the product is added to cart.voidsetPriceSearchCriteriaInContext(PriceLevel priceLevel) Method to set price search criteria in session context These values will be used to retrieve prices during cart calculation when the product is added to cart.voidsetProductService(de.hybris.platform.product.ProductService productService) voidsetSessionService(de.hybris.platform.servicelayer.session.SessionService sessionService) Sets session service.voidsetTaxSearchCriteriaInContext(List<String> transportOfferingCodes, String passengerType) Method to set values in Session Context.voidsetTimeService(de.hybris.platform.servicelayer.time.TimeService timeService) Sets time service.voidsetTransportFacilityService(TransportFacilityService transportFacilityService) Sets transport facility service.voidsetTransportOfferingService(TransportOfferingService transportOfferingService) Sets transport offering service.voidsetTravelCommerceCartService(TravelCommerceCartService travelCommerceCartService) Sets travel commerce cart service.voidsetTravellerService(TravellerService travellerService) Sets traveller service.voidsetTravelPDTRowDao(TravelPDTRowDao travelPDTRowDao) 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
-
DefaultTravelCommercePriceService
public DefaultTravelCommercePriceService()
-
-
Method Details
-
getProductWebPrice
public de.hybris.platform.jalo.order.price.PriceInformation getProductWebPrice(ProductModel product, Map<String, String> searchCriteria) Description copied from interface:TravelCommercePriceServiceMethod to retrieve price for the product and travel specific search criteria- Specified by:
getProductWebPricein interfaceTravelCommercePriceService- Parameters:
product- the productsearchCriteria- the map that has travel specific search criteria- Returns:
- PriceInformation product web price
-
getCurrentPriceFactory
-
getProductTaxInformations
public List<de.hybris.platform.jalo.order.price.TaxInformation> getProductTaxInformations(ProductModel product) Description copied from interface:TravelCommercePriceServiceMethod to retrieve taxes for the product- Specified by:
getProductTaxInformationsin interfaceTravelCommercePriceService- Parameters:
product- the product- Returns:
- TaxInformation product tax informations
-
getPriceInformation
public de.hybris.platform.jalo.order.price.PriceInformation getPriceInformation(ProductModel product, String searchKey, String searchValue) Description copied from interface:TravelCommercePriceServiceThis method gets the price information for product code, search key and search value.- Specified by:
getPriceInformationin interfaceTravelCommercePriceService- Parameters:
product- the productsearchKey- the search keysearchValue- the search value- Returns:
- PriceInformation price information
-
getPriceLevelInfo
public PriceLevel getPriceLevelInfo(String productCode, List<String> transportOfferings, String routeCode, boolean isMultiSectorRoute) Description copied from interface:TravelCommercePriceServiceMethod to find the price level info. The first available price information is used to build the map.- Specified by:
getPriceLevelInfoin interfaceTravelCommercePriceService- Parameters:
productCode- the product codetransportOfferings- the transport offeringsrouteCode- the route codeisMultiSectorRoute- the is multi sector route- Returns:
- the price level info
-
getPriceLevelInfoForFareProduct
public PriceLevel getPriceLevelInfoForFareProduct(ProductModel productModel, List<String> transportOfferings, String routeCode, boolean isMultiSectorRoute) Description copied from interface:TravelCommercePriceServiceMethod to return price level info as a map, with price level as key and code as value. Null is returned if route level price is not set for multi sector route.- Specified by:
getPriceLevelInfoForFareProductin interfaceTravelCommercePriceService- Returns:
- price level info
-
getPriceLevelInfoForAncillary
public PriceLevel getPriceLevelInfoForAncillary(ProductModel productModel, String transportOfferingCode, String routeCode) Method to return price level info as a map, with price level as key and code as value.- Specified by:
getPriceLevelInfoForAncillaryin interfaceTravelCommercePriceService- Parameters:
productModel-transportOfferingCode-routeCode-- Returns:
- price level info
-
isNetPricedProduct
Description copied from interface:TravelCommercePriceServiceReturn true if the product is net priced, false otherwise- Specified by:
isNetPricedProductin interfaceTravelCommercePriceService- Returns:
-
getPriceLevelInfoByHierarchy
public PriceLevel getPriceLevelInfoByHierarchy(ProductModel product, String transportOfferingCode, String routeCode) Description copied from interface:TravelCommercePriceServiceMethod to get the price level and value for product code, search key and search value. The price level is searched in the order of transportoffering, sector, route and default price. The first available price level will be returned.- Specified by:
getPriceLevelInfoByHierarchyin interfaceTravelCommercePriceService- Parameters:
product- the producttransportOfferingCode- the transport offering coderouteCode- the route code- Returns:
- price level
-
isPriceInformationAvailable
public boolean isPriceInformationAvailable(ProductModel product, String searchKey, String searchValue) Description copied from interface:TravelCommercePriceServiceMethod to check if the price information is available for the given search criteria- Specified by:
isPriceInformationAvailablein interfaceTravelCommercePriceService- Parameters:
product- the productsearchKey- the search keysearchValue- the search value- Returns:
- boolean boolean
-
setPriceAndTaxSearchCriteriaInContext
public void setPriceAndTaxSearchCriteriaInContext(PriceLevel priceLevel, List<String> transportOfferingCodes, String passengerType) Description copied from interface:TravelCommercePriceServiceMethod to set price and tax search criteria in session context These values will be used to retrieve prices during cart calculation when the product is added to cart.- Specified by:
setPriceAndTaxSearchCriteriaInContextin interfaceTravelCommercePriceService- Parameters:
priceLevel- the price leveltransportOfferingCodes- the transport offering codespassengerType- the passenger type
-
setPriceSearchCriteriaInContext
Description copied from interface:TravelCommercePriceServiceMethod to set price search criteria in session context These values will be used to retrieve prices during cart calculation when the product is added to cart.- Specified by:
setPriceSearchCriteriaInContextin interfaceTravelCommercePriceService- Parameters:
priceLevel- the price level
-
setTaxSearchCriteriaInContext
public void setTaxSearchCriteriaInContext(List<String> transportOfferingCodes, String passengerType) Description copied from interface:TravelCommercePriceServiceMethod to set values in Session Context. These values will be used to retrieve taxes during cart calculation when the product is added to cart.- Specified by:
setTaxSearchCriteriaInContextin interfaceTravelCommercePriceService- Parameters:
transportOfferingCodes- the transport offering codespassengerType- the passenger type
-
addPropertyPriceLevelToCartEntry
public void addPropertyPriceLevelToCartEntry(PriceLevel priceLevel, String productCode, int entryNo) Description copied from interface:TravelCommercePriceServiceMethod to add price level property to cart entry- Specified by:
addPropertyPriceLevelToCartEntryin interfaceTravelCommercePriceService- Parameters:
priceLevel- the price levelproductCode- the product codeentryNo- the entry no
-
getProductService
protected de.hybris.platform.product.ProductService getProductService() -
setProductService
public void setProductService(de.hybris.platform.product.ProductService productService) -
getOfferGroupToOriginDestinationMapping
-
setOfferGroupToOriginDestinationMapping
-
getModelService
protected de.hybris.platform.servicelayer.model.ModelService getModelService()Gets model service.- Returns:
- model service
-
setModelService
public void setModelService(de.hybris.platform.servicelayer.model.ModelService modelService) Sets model service.- Parameters:
modelService- the model service
-
getTransportOfferingService
Gets transport offering service.- Returns:
- the transport offering service
-
setTransportOfferingService
Sets transport offering service.- Parameters:
transportOfferingService- the transport offering service
-
getSessionService
protected de.hybris.platform.servicelayer.session.SessionService getSessionService()Gets session service.- Returns:
- the session service
-
setSessionService
public void setSessionService(de.hybris.platform.servicelayer.session.SessionService sessionService) Sets session service.- Parameters:
sessionService- the session service
-
getTransportFacilityService
Gets transport facility service.- Returns:
- the transport facility service
-
setTransportFacilityService
Sets transport facility service.- Parameters:
transportFacilityService- the transport facility service
-
getCartService
protected de.hybris.platform.order.CartService getCartService()Gets cart service.- Returns:
- the cart service
-
setCartService
public void setCartService(de.hybris.platform.order.CartService cartService) Sets cart service.- Parameters:
cartService- the cart service
-
getTravelCommerceCartService
Gets travel commerce cart service.- Returns:
- the travel commerce cart service
-
setTravelCommerceCartService
Sets travel commerce cart service.- Parameters:
travelCommerceCartService- the travel commerce cart service
-
getTravellerService
Gets traveller service.- Returns:
- the traveller service
-
setTravellerService
Sets traveller service.- Parameters:
travellerService- the traveller service
-
getTimeService
protected de.hybris.platform.servicelayer.time.TimeService getTimeService()Gets time service.- Returns:
- timeService time service
-
setTimeService
public void setTimeService(de.hybris.platform.servicelayer.time.TimeService timeService) Sets time service.- Parameters:
timeService- the timeService to set
-
getTravelPDTRowDao
- Returns:
- the travelPDTRowDao
-
setTravelPDTRowDao
- Parameters:
travelPDTRowDao- the travelPDTRowDao to set
-