Class DefaultMarketBucketService

java.lang.Object
de.hybris.platform.unifieduibackofficeservices.service.impl.DefaultMarketBucketService
All Implemented Interfaces:
MarketBucketService

public class DefaultMarketBucketService extends Object implements MarketBucketService
This service will provide integration with the pros api to call market buckets related api's
  • Field Details

  • Constructor Details

    • DefaultMarketBucketService

      public DefaultMarketBucketService()
  • Method Details

    • getMarketBuckets

      public List<MarketBucket> getMarketBuckets(Map<String,Object> searchFilterMap)
      This method returns the market buckets by calling pros service.
      Specified by:
      getMarketBuckets in interface MarketBucketService
      Parameters:
      searchFilterMap - the map of filters to apply to the request
      Returns:
      list of market bucket
    • removeMarket

      public boolean removeMarket(MarketBucket marketBucket) throws org.springframework.web.client.HttpServerErrorException, org.springframework.web.client.ResourceAccessException
      This method removes the market bucket by calling pros service.
      Specified by:
      removeMarket in interface MarketBucketService
      Parameters:
      marketBucket - the marketBucket
      Returns:
      the boolean, return true if market bucket is removed in pros
      Throws:
      org.springframework.web.client.HttpServerErrorException - the exception when http response is not 200
      org.springframework.web.client.ResourceAccessException - the resource is not accessible exception
    • createMarketBucket

      public boolean createMarketBucket(MarketBucket marketBucket) throws org.springframework.web.client.HttpServerErrorException, org.springframework.web.client.HttpClientErrorException, org.springframework.web.client.ResourceAccessException
      This method creates market bucket in pros
      Specified by:
      createMarketBucket in interface MarketBucketService
      Parameters:
      marketBucket - the marketBucket
      Returns:
      the boolean, return true if market bucket is created in pros else return false
      Throws:
      org.springframework.web.client.HttpServerErrorException - the exception when http response is not 200 e.g. status 5xx
      org.springframework.web.client.HttpClientErrorException - the exception when http response is not 200 e.g. status 4xx
      org.springframework.web.client.ResourceAccessException - the resource is not accessible exception
    • getMarketBucket

      public MarketBucket getMarketBucket(MarketBucket marketBucket)
      This method returns the MarketBucket by marketBucketEntityId and username by calling pros service.
      Specified by:
      getMarketBucket in interface MarketBucketService
      Parameters:
      marketBucket - the marketBucket
      Returns:
      the MarketBucket
    • updateMarketBucket

      public boolean updateMarketBucket(MarketBucket marketBucket) throws org.springframework.web.client.HttpServerErrorException, org.springframework.web.client.HttpClientErrorException, org.springframework.web.client.ResourceAccessException
      This method updates marketBucket in pros
      Specified by:
      updateMarketBucket in interface MarketBucketService
      Parameters:
      marketBucket - the marketBucket
      Returns:
      the boolean, return true if marketBucket is updated in pros
      Throws:
      org.springframework.web.client.HttpServerErrorException - the exception when http response is not 200 e.g. status 5xx
      org.springframework.web.client.HttpClientErrorException - the exception when http response is not 200 e.g. status 4xx
      org.springframework.web.client.ResourceAccessException - the resource is not accessible exception
    • getProsEndpoint

      protected String getProsEndpoint()
      This method return the pros server end point as configured.
      Returns:
      the pros end point
    • getMarketBucketEndpoint

      protected String getMarketBucketEndpoint()
      This method return the market bucket end point as configured.
      Returns:
      the market end point
    • getConfigurationService

      protected de.hybris.platform.servicelayer.config.ConfigurationService getConfigurationService()
      Returns:
      the configurationService
    • setConfigurationService

      public void setConfigurationService(de.hybris.platform.servicelayer.config.ConfigurationService configurationService)
      Parameters:
      configurationService - the configurationService to set
    • getBackofficeRestTemplate

      protected org.springframework.web.client.RestTemplate getBackofficeRestTemplate()
      Returns:
      the backofficeRestTemplate
    • setBackofficeRestTemplate

      public void setBackofficeRestTemplate(org.springframework.web.client.RestTemplate backofficeRestTemplate)
      Parameters:
      backofficeRestTemplate - the backofficeRestTemplate to set