Class AbstractSearchUIColumn
- java.lang.Object
-
- org.ametys.runtime.parameter.Parameter<MetadataType>
-
- org.ametys.cms.search.ui.model.impl.AbstractSearchUIColumn
-
- All Implemented Interfaces:
Field,ResultField,SearchUIColumn
- Direct Known Subclasses:
MetadataSearchUIColumn,SystemSearchUIColumn
public abstract class AbstractSearchUIColumn extends Parameter<MetadataType> implements SearchUIColumn
This class represents a result column
-
-
Constructor Summary
Constructors Constructor Description AbstractSearchUIColumn()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected I18nizableText_configureI18nizableText(Configuration config, I18nizableText defaultValue)Configure an i18nizable textStringgetContentTypeId()Get the content type ID (only when the search criteria is of type CONTENT).StringgetConverter()Get the JS class name for converting field's valueStringgetDefaultSorter()If the column should be the default sorter 'ASC' or 'DESC'.StringgetRenderer()Get the JS class name for rendererSearchFieldgetSearchField()Get theSearchFieldrepresenting this result field.intgetWidth()The column's widthbooleanisEditable()Determines if the property is editablebooleanisHidden()Determines if the column is hidden by defaultbooleanisMultiple()Get the multiple status of the field.booleanisSortable()Determines if the column is sortablevoidsetContentTypeId(String contentTypeId)Set the content type ID (only when the search criteria is of type CONTENT).voidsetConverter(String converter)Set the JS class name for converting field's valuevoidsetDefaultSorter(String defaultSorter)Set the default sorter properyvoidsetEditable(boolean editable)Set the editable propertyvoidsetHidden(boolean hidden)Set the hidden propertyvoidsetMultiple(boolean multiple)Set the multiple propertyvoidsetRenderer(String renderer)Set the JS class name for renderervoidsetSortable(boolean sortable)Set the sortable propertyvoidsetWidth(int width)Set the column's width-
Methods inherited from class org.ametys.runtime.parameter.Parameter
getDefaultValue, getDescription, getEnumerator, getId, getLabel, getPluginName, getType, getValidator, getWidget, getWidgetParameters, setDefaultValue, setDescription, setEnumerator, setId, setLabel, setPluginName, setType, setValidator, setWidget, setWidgetParameters
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.ametys.cms.search.model.Field
getEnumerator, getType
-
Methods inherited from interface org.ametys.cms.search.model.ResultField
getFullValue, getId, getValue
-
Methods inherited from interface org.ametys.cms.search.ui.model.SearchUIColumn
getDescription, getLabel, getSubColumns, getValidator, getWidget, getWidgetParameters
-
-
-
-
Constructor Detail
-
AbstractSearchUIColumn
public AbstractSearchUIColumn()
-
-
Method Detail
-
getWidth
public int getWidth()
Description copied from interface:SearchUIColumnThe column's width- Specified by:
getWidthin interfaceSearchUIColumn- Returns:
- The width
-
setWidth
public void setWidth(int width)
Set the column's width- Parameters:
width- The width to set
-
isHidden
public boolean isHidden()
Description copied from interface:SearchUIColumnDetermines if the column is hidden by default- Specified by:
isHiddenin interfaceSearchUIColumn- Returns:
trueif the column is hidden by default
-
setHidden
public void setHidden(boolean hidden)
Set the hidden property- Parameters:
hidden-trueto hidden the columns by default
-
isEditable
public boolean isEditable()
Description copied from interface:SearchUIColumnDetermines if the property is editable- Specified by:
isEditablein interfaceSearchUIColumn- Returns:
trueif the property is editable
-
setSortable
public void setSortable(boolean sortable)
Set the sortable property- Parameters:
sortable-trueto authorized sort
-
isSortable
public boolean isSortable()
Description copied from interface:SearchUIColumnDetermines if the column is sortable- Specified by:
isSortablein interfaceSearchUIColumn- Returns:
trueif the column is sortable
-
setDefaultSorter
public void setDefaultSorter(String defaultSorter)
Set the default sorter propery- Parameters:
defaultSorter- If the column should be a default sorter, 'ASC' for ascending 'DESC' for descending. Null otherwise.
-
getDefaultSorter
public String getDefaultSorter()
Description copied from interface:SearchUIColumnIf the column should be the default sorter 'ASC' or 'DESC'. Null otherwise.- Specified by:
getDefaultSorterin interfaceSearchUIColumn- Returns:
- 'ASC', 'DESC' or null
-
setEditable
public void setEditable(boolean editable)
Set the editable property- Parameters:
editable-trueto authorized edition
-
getRenderer
public String getRenderer()
Description copied from interface:SearchUIColumnGet the JS class name for renderer- Specified by:
getRendererin interfaceSearchUIColumn- Returns:
- The renderer
-
setRenderer
public void setRenderer(String renderer)
Set the JS class name for renderer- Parameters:
renderer- The renderer
-
getConverter
public String getConverter()
Description copied from interface:SearchUIColumnGet the JS class name for converting field's value- Specified by:
getConverterin interfaceSearchUIColumn- Returns:
- The convert JS class name
-
setConverter
public void setConverter(String converter)
Set the JS class name for converting field's value- Parameters:
converter- The convert JS class name
-
isMultiple
public boolean isMultiple()
Description copied from interface:FieldGet the multiple status of the field.- Specified by:
isMultiplein interfaceField- Returns:
trueif the field can have multiple values,falseotherwise.
-
setMultiple
public void setMultiple(boolean multiple)
Set the multiple property- Parameters:
multiple- the multiple property
-
getContentTypeId
public String getContentTypeId()
Get the content type ID (only when the search criteria is of type CONTENT).- Specified by:
getContentTypeIdin interfaceField- Returns:
- the content type ID.
-
setContentTypeId
public void setContentTypeId(String contentTypeId)
Set the content type ID (only when the search criteria is of type CONTENT).- Parameters:
contentTypeId- the content type ID.
-
getSearchField
public SearchField getSearchField()
Description copied from interface:ResultFieldGet theSearchFieldrepresenting this result field.- Specified by:
getSearchFieldin interfaceResultField- Returns:
- The
SearchFieldrepresenting this result field.
-
_configureI18nizableText
protected I18nizableText _configureI18nizableText(Configuration config, I18nizableText defaultValue)
Configure an i18nizable text- Parameters:
config- The Configuration.defaultValue- The default value as an I18nizableText.- Returns:
- The i18nizable text
-
-