Interface Grid<G extends Grid<G>>
-
- All Superinterfaces:
Comparable<G>
,Component<G>
,Copyable<G>
,Serializable
- All Known Subinterfaces:
ActionGrid<G>
,EntityGridView<V>
,ExportGrid<G>
,ExportHistoryEntityGridView<V>
,ExportHistoryGrid<G>
,ExportHistoryGridExternal<E>
,FetchGrid<G>
,FilterableGrid<G>
,GridExternal<E>
,GridView<V>
,ImportGrid<G>
,LookupFieldModal<V>
,Orderable<R>
,ResidentGridField<F>
,ResidentMapField<F>
,ResourceGrid<G>
,SelectTargetEntityGridView<V>
,SortableGrid<G>
,TreeGridView<V>
- All Known Implementing Classes:
DefaultEntityGridView
,DefaultExportHistoryEntityGridView
,DefaultExportHistoryGridExternal
,DefaultGridExternal
,DefaultLookupFieldModal
,DefaultResidentGridField
,DefaultResidentMapField
,DefaultSelectTargetEntityGridView
,DefaultTreeGridView
public interface Grid<G extends Grid<G>> extends Component<G>
An interface representing a grid with a collection ofColumn
.- Author:
- Nick Crum (ncrum)
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
Grid.Attributes
static class
Grid.Keys
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default G
addColumn(Column<?> column)
Adds a column to this grid.default G
addColumn(String name)
Adds a string column with the given name to this grid.default G
addColumn(String name, Column<?> column)
Adds a column with the given property name to this grid.default G
addColumns(Collection<Column<?>> columns)
Adds a collection of columns to this grid.default Optional<Column<?>>
findColumn(String name)
Finds the column with the given property name.default Column<?>
getColumn(String name)
Retrieves the column with the given property name, if it exists.default G
idKey(String idKey)
Define the property used as the unique identifier for the data in a row.default G
removeColumn(String name)
Removes the column with the given name.-
Methods inherited from interface java.lang.Comparable
compareTo
-
Methods inherited from interface com.broadleafcommerce.metadata.dsl.core.Component
addAction, addAction, addComponent, addEndpoint, addEndpoint, apply, attribute, augmentationKey, classifier, clearConditionals, clearEndpoints, conditional, conditionals, description, description, findAction, findAction, findActions, findAttribute, findComponent, findComponent, findComponents, findEndpoint, findEndpoint, findEndpoints, get, get, getAction, getAction, getActions, getActionsList, getAttribute, getAttribute, getAttributes, getAugmentationKey, getClassifier, getComponent, getComponent, getComponents, getComponentsList, getConditionals, getDescription, getEndpoint, getEndpoint, getEndpoints, getEndpointsList, getId, getLabel, getOrder, getScope, getType, hasAction, hasAttribute, hasComponent, hasEndpoint, id, isAugmentable, isTranslatable, label, label, notTranslatable, order, removeAction, removeAttribute, removeComponent, removeEndpoint, scope, self, setActions, setAttributes, setAugmentationKey, setClassifier, setComponents, setConditionals, setDescription, setEndpoints, setId, setLabel, setOrder, setScope, setTranslatable, setType, translatable, translatable, type
-
-
-
-
Method Detail
-
idKey
default G idKey(String idKey)
Define the property used as the unique identifier for the data in a row. Defaults to "id" in the client.- Parameters:
idKey
- the id field- Returns:
- this
-
addColumns
default G addColumns(Collection<Column<?>> columns)
Adds a collection of columns to this grid.- Parameters:
columns
- the columns to add- Returns:
- this
-
addColumn
default G addColumn(String name, Column<?> column)
Adds a column with the given property name to this grid.- Parameters:
name
- the name of the propertycolumn
- the column- Returns:
- this
-
addColumn
default G addColumn(Column<?> column)
Adds a column to this grid.- Parameters:
column
- the column- Returns:
- this
-
addColumn
default G addColumn(String name)
Adds a string column with the given name to this grid. Capitalizes the provided name as the label for the column.- Parameters:
name
- the name of the property- Returns:
- this
-
removeColumn
default G removeColumn(String name)
Removes the column with the given name.- Parameters:
name
- the column name- Returns:
- this
-
getColumn
default Column<?> getColumn(String name)
Retrieves the column with the given property name, if it exists.- Parameters:
name
- the name of the property- Returns:
- the column
- Throws:
IllegalArgumentException
- if no component is found with that key
-
-