Interface FacetValueDisplayNameProvider

All Known Implementing Classes:
AbstractFacetValueDisplayNameProvider, ColorFacetDisplayNameProvider, CommerceCategoryFacetDisplayNameProvider, CustomerCouponFacetDisplayNameProvider, GenderFacetDisplayNameProvider, PointOfServiceFacetDisplayNameProvider, PointOfServiceFacetDisplayNameProvider, ProductVendorFacetDisplayNameProvider, PromotionFacetDisplayNameProvider

public interface FacetValueDisplayNameProvider
Interface used to lookup a display name for a specific facet value. Facet values retrieved from Solr are simple strings which cannot encode localised display values, therefore this interface can be used to provide additional displayable data for the facet value. A spring bean that implements the FacetDisplayNameProvider interface can be associated with an IndexedProperty and is then used to resolve a display name for a specific facet value. The FacetDisplayNameProvider interface is deprecated in favour of this interface, however implementers of this interface must also implement the FacetDisplayNameProvider interface otherwise they cannot be associated with the IndexedProperty. Where a bean implements both this interface and the FacetDisplayNameProvider interface then this interface will be called in preference. Implementers should typically extend the AbstractFacetValueDisplayNameProvider class.
  • Method Details

    • getDisplayName

      String getDisplayName(SearchQuery query, IndexedProperty property, String facetValue)
      Get the display name for a facet value.
      Parameters:
      query - The search query
      property - The indexed property (i.e. the facet)
      facetValue - The facet value
      Returns:
      The display name for the specified facet value.