Class AccommodationOfferingBasicPopulator

java.lang.Object
de.hybris.platform.travelfacades.populators.AccommodationOfferingBasicPopulator
All Implemented Interfaces:
de.hybris.platform.converters.Populator<AccommodationOfferingModel,PropertyData>

public class AccommodationOfferingBasicPopulator extends Object implements de.hybris.platform.converters.Populator<AccommodationOfferingModel,PropertyData>
The type Accommodation offering basic populator.
  • Constructor Details

    • AccommodationOfferingBasicPopulator

      public AccommodationOfferingBasicPopulator()
  • Method Details

    • populate

      public void populate(AccommodationOfferingModel source, PropertyData target) throws de.hybris.platform.servicelayer.dto.converter.ConversionException
      Specified by:
      populate in interface de.hybris.platform.converters.Populator<AccommodationOfferingModel,PropertyData>
      Throws:
      de.hybris.platform.servicelayer.dto.converter.ConversionException
    • addLocation

      protected void addLocation(AccommodationOfferingModel source, PropertyData target)
      Populates location to property data.
      Parameters:
      source - the accommodation offering model
      target - the property data
    • getAccommodationOfferingTypes

      protected List<String> getAccommodationOfferingTypes(AccommodationOfferingModel accommodationOfferingModel)
      Get accommodation offering type list.
      Parameters:
      accommodationOfferingModel - the accommodation offering model
      Returns:
      the list
    • getAddressData

      protected AddressData getAddressData(AccommodationOfferingModel accommodationOfferingModel)
      Gets address data.
      Parameters:
      accommodationOfferingModel - the accommodation offering model
      Returns:
      the address data
    • getAwards

      protected List<AwardData> getAwards(AccommodationOfferingModel accommodationOfferingModel)
      Gets awards.
      Parameters:
      accommodationOfferingModel - the accommodation offering model
      Returns:
      the awards
    • getPosition

      protected PositionData getPosition(LocationModel location)
      Gets position.
      Parameters:
      location - the location
      Returns:
      the position
    • addImagesInFormats

      protected void addImagesInFormats(MediaContainerModel mediaContainer, ImageDataType imageType, int galleryIndex, List<ImageData> imagesList)
      This method will add on the images list the medias converted from the given media container. If the imageType is of type GALLERY then also the galleryIndex is set on the Image data
      Parameters:
      mediaContainer - the media container
      imageType - the image type
      galleryIndex - the gallery index
      imagesList - the images list
    • getMediaContainerForSelectedAccommodation

      protected List<MediaContainerModel> getMediaContainerForSelectedAccommodation(String galleryCode)
      Gets media container for selected accommodation.
      Parameters:
      galleryCode - the gallery code
      Returns:
      the media container for selected accommodation
    • getCatalogVersion

      protected CatalogVersionModel getCatalogVersion()
      Gets catalog version.
      Returns:
      the catalog version
    • getAccommodationOfferingGalleryService

      protected AccommodationOfferingGalleryService getAccommodationOfferingGalleryService()
      Gets accommodation offering gallery service.
      Returns:
      the accommodation offering gallery service
    • setAccommodationOfferingGalleryService

      public void setAccommodationOfferingGalleryService(AccommodationOfferingGalleryService accommodationOfferingGalleryService)
      Sets accommodation offering gallery service.
      Parameters:
      accommodationOfferingGalleryService - the accommodation offering gallery service
    • getCatalogVersionService

      protected de.hybris.platform.catalog.CatalogVersionService getCatalogVersionService()
      Gets catalog version service.
      Returns:
      the catalog version service
    • setCatalogVersionService

      public void setCatalogVersionService(de.hybris.platform.catalog.CatalogVersionService catalogVersionService)
      Sets catalog version service.
      Parameters:
      catalogVersionService - the catalog version service
    • getImageFormats

      protected List<String> getImageFormats()
      Gets image formats.
      Returns:
      the image formats
    • setImageFormats

      public void setImageFormats(List<String> imageFormats)
      Sets image formats.
      Parameters:
      imageFormats - the image formats
    • getImageFormatMapping

      protected de.hybris.platform.commercefacades.product.ImageFormatMapping getImageFormatMapping()
      Gets image format mapping.
      Returns:
      the image format mapping
    • setImageFormatMapping

      public void setImageFormatMapping(de.hybris.platform.commercefacades.product.ImageFormatMapping imageFormatMapping)
      Sets image format mapping.
      Parameters:
      imageFormatMapping - the image format mapping
    • getMediaService

      protected de.hybris.platform.servicelayer.media.MediaService getMediaService()
      Gets media service.
      Returns:
      the media service
    • setMediaService

      public void setMediaService(de.hybris.platform.servicelayer.media.MediaService mediaService)
      Sets media service.
      Parameters:
      mediaService - the media service
    • getImageConverter

      protected de.hybris.platform.servicelayer.dto.converter.Converter<MediaModel,ImageData> getImageConverter()
      Gets image converter.
      Returns:
      the image converter
    • setImageConverter

      public void setImageConverter(de.hybris.platform.servicelayer.dto.converter.Converter<MediaModel,ImageData> imageConverter)
      Sets image converter.
      Parameters:
      imageConverter - the image converter
    • getMediaContainerService

      protected de.hybris.platform.servicelayer.media.MediaContainerService getMediaContainerService()
      Gets media container service.
      Returns:
      the media container service
    • setMediaContainerService

      public void setMediaContainerService(de.hybris.platform.servicelayer.media.MediaContainerService mediaContainerService)
      Sets media container service.
      Parameters:
      mediaContainerService - the media container service
    • getPropertyFacilityConverter

      protected de.hybris.platform.converters.impl.AbstractPopulatingConverter<PropertyFacilityModel,FacilityData> getPropertyFacilityConverter()
      Gets property facility converter.
      Returns:
      the propertyFacilityConverter
    • setPropertyFacilityConverter

      public void setPropertyFacilityConverter(de.hybris.platform.converters.impl.AbstractPopulatingConverter<PropertyFacilityModel,FacilityData> propertyFacilityConverter)
      Sets property facility converter.
      Parameters:
      propertyFacilityConverter - the propertyFacilityConverter to set
    • getConfiguredFacilityDataComparator

      protected Comparator<FacilityData> getConfiguredFacilityDataComparator()
      Gets configured facility data comparator.
      Returns:
      the configuredFacilityDataComparator
    • setConfiguredFacilityDataComparator

      public void setConfiguredFacilityDataComparator(Comparator<FacilityData> configuredFacilityDataComparator)
      Sets configured facility data comparator.
      Parameters:
      configuredFacilityDataComparator - the configuredFacilityDataComparator to set
    • getAddressConverter

      protected de.hybris.platform.converters.impl.AbstractPopulatingConverter<AddressModel,AddressData> getAddressConverter()
      Gets address converter.
      Returns:
      the addressConverter
    • setAddressConverter

      public void setAddressConverter(de.hybris.platform.converters.impl.AbstractPopulatingConverter<AddressModel,AddressData> addressConverter)
      Sets address converter.
      Parameters:
      addressConverter - the addressConverter to set
    • getLocationConverter

      protected de.hybris.platform.servicelayer.dto.converter.Converter<LocationModel,LocationData> getLocationConverter()
      Gets location converter.
      Returns:
      the location converter
    • setLocationConverter

      public void setLocationConverter(de.hybris.platform.servicelayer.dto.converter.Converter<LocationModel,LocationData> locationConverter)
      Sets location converter.
      Parameters:
      locationConverter - the location converter