Class Facet

java.lang.Object
com.hybris.merchandising.model.Facet
All Implemented Interfaces:
Serializable

public class Facet extends Object implements Serializable
This object is the list of facets that the user has selected in the UI to narrow down the search of products
See Also:
  • Constructor Details

    • Facet

      public Facet()
      Creates a new instance of an ItemFacet with an empty list of values.
    • Facet

      public Facet(String code, String name)
      Creates a new instance of an ItemFacet with a specified code and name.
      Parameters:
      code - a String containing the code for the specific facet.
      name - the name of the specific facet.
    • Facet

      public Facet(String code, String name, List<String> values)
      Creates a new instance of an ItemFacet with a specific code, name and initial values.
      Parameters:
      code - a String containing the code for the specific facet.
      name - the name of the specific facet.
      values - a list of the values we want to store against this facet.
  • Method Details

    • setCode

      public void setCode(String code)
    • getCode

      public String getCode()
    • setName

      public void setName(String name)
    • getName

      public String getName()
    • setValues

      public void setValues(List<String> values)
    • addValue

      public void addValue(String value)
      Adds a specified facet value to the list of values represented by this current facet.
      Parameters:
      value - the facet value to add to the list.
    • getValues

      public List<String> getValues()
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object object)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object