Class DefaultSearchField
- java.lang.Object
-
- de.hybris.platform.cockpit.model.advancedsearch.impl.DefaultSearchField
-
- All Implemented Interfaces:
SearchField
public class DefaultSearchField extends java.lang.Object implements SearchField
DefaultSearchFieldimplementation.- See Also:
SearchField
-
-
Constructor Summary
Constructors Constructor Description DefaultSearchField(java.lang.String name, boolean sortable)Creates a newDefaultSearchFieldinstance with the name set tonameand the sortable status set tosortable.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)SearchFieldGroupgetGroup()Returns thegroupto which this search field has been assigned.java.lang.StringgetLabel()Returns the (localized) label of this field.java.lang.StringgetName()Returns the name of this field.inthashCode()booleanisSortable()Returns whether this field is sortable or not.booleanisVisible()Returns whether this field is visible or not.voidsetGroup(SearchFieldGroup group)voidsetLabel(java.lang.String label)voidsetName(java.lang.String name)Sets the name of this search field toname.voidsetSortDisabled(boolean sortDisabled)Sets whether sorting based on this search field should be disabled or not.voidsetVisible(boolean visible)Sets the visibility of this search field tovisible.
-
-
-
Constructor Detail
-
DefaultSearchField
public DefaultSearchField(java.lang.String name, boolean sortable)Creates a newDefaultSearchFieldinstance with the name set tonameand the sortable status set tosortable.- Parameters:
name- name of this search fieldsortable- whether this search field supports sorting
-
-
Method Detail
-
getName
public java.lang.String getName()
Description copied from interface:SearchFieldReturns the name of this field.- Specified by:
getNamein interfaceSearchField- Returns:
- name of this field
-
setLabel
public void setLabel(java.lang.String label)
-
getLabel
public java.lang.String getLabel()
Description copied from interface:SearchFieldReturns the (localized) label of this field.- Specified by:
getLabelin interfaceSearchField- Returns:
- label of this field
-
isSortable
public boolean isSortable()
Description copied from interface:SearchFieldReturns whether this field is sortable or not.- Specified by:
isSortablein interfaceSearchField- Returns:
trueif this field is sortable,falseotherwise
-
isVisible
public boolean isVisible()
Description copied from interface:SearchFieldReturns whether this field is visible or not.- Specified by:
isVisiblein interfaceSearchField- Returns:
trueif this field is visible,falseotherwise
-
setName
public void setName(java.lang.String name)
Sets the name of this search field toname.- Parameters:
name- the name of this search field
-
setVisible
public void setVisible(boolean visible)
Sets the visibility of this search field tovisible.- Parameters:
visible-truemeans that this search field is set as visible, whereasfalsemeans invisible
-
setSortDisabled
public void setSortDisabled(boolean sortDisabled)
Sets whether sorting based on this search field should be disabled or not.- Parameters:
sortDisabled-truemeans that sorting by this search field is disabled i.e. not allowed, whereastruemeans that sorting is allowed if possible.
-
getGroup
public SearchFieldGroup getGroup()
Description copied from interface:SearchFieldReturns thegroupto which this search field has been assigned.- Specified by:
getGroupin interfaceSearchField- Returns:
- the group which contains this search field
-
setGroup
public void setGroup(SearchFieldGroup group)
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
-