com.vaadin.flow.component.crud.
Class CrudGrid<E>
- java.lang.Object
-
- com.vaadin.flow.component.Component
-
- com.vaadin.flow.component.grid.Grid<E>
-
- com.vaadin.flow.component.crud.CrudGrid<E>
-
Type Parameters:
E
- the bean typeAll Implemented Interfaces:
AttachNotifier, BlurNotifier<Grid<E>>, DetachNotifier, Focusable<Grid<E>>, FocusNotifier<Grid<E>>, HasElement, HasEnabled, HasSize, HasStyle, HasTheme, SortEvent.SortNotifier<Grid<E>,GridSortOrder<E>>, HasDataGenerators<E>, HasDataView<E,Void,GridDataView<E>>, HasLazyDataView<E,Void,GridLazyDataView<E>>, HasListDataView<E,GridListDataView<E>>, Serializable
public class CrudGrid<E> extends Grid<E>
A simple grid implementation for Crud that allows searching and sorting backed by a data provider.
See Also:
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.vaadin.flow.component.grid.Grid
Grid.AbstractGridExtension<T>, Grid.Column<T>, Grid.DataCommunicatorBuilder<T,U extends ArrayUpdater>, Grid.SelectionMode, Grid.UpdateQueue
-
Nested classes/interfaces inherited from interface com.vaadin.flow.component.BlurNotifier
BlurNotifier.BlurEvent<C extends Component>
-
Nested classes/interfaces inherited from interface com.vaadin.flow.component.FocusNotifier
FocusNotifier.FocusEvent<C extends Component>
-
-
Constructor Summary
Constructors Constructor and Description CrudGrid(Class<E> beanType, boolean enableDefaultFilters)
Instantiates a new CrudGrid for the supplied bean type.
-
Method Summary
All Methods Modifier and Type Method and Description DataProvider<E,?>
getDataProvider()
Gets the data provider set to the grid.
CrudFilter
getFilter()
Gets the filter applied to this grid
void
setDataProvider(DataProvider<E,?> dataProvider)
Sets a DataProvider<E, CrudFilter>
-
Methods inherited from class com.vaadin.flow.component.grid.Grid
addColumn, addColumn, addColumn, addColumn, addColumn, addColumn, addColumn, addColumn, addColumn, addColumnReorderListener, addColumnResizeListener, addColumns, addComponentColumn, addContextMenu, addDataGenerator, addDragEndListener, addDragStartListener, addDropListener, addFirstHeaderRow, addItemClickListener, addItemDoubleClickListener, addSelectionListener, addSortListener, addThemeVariants, addValueProvider, appendFooterRow, appendHeaderRow, asMultiSelect, asSingleSelect, compareMaybeComparables, createColumn, createColumnId, createDefaultArrayUpdater, createEditor, createSortingComparator, deselect, deselectAll, getArrayUpdater, getBeanType, getClassNameGenerator, getColumnByKey, getColumnLayers, getColumns, getDataCommunicator, getDefaultColumnFactory, getDefaultHeaderRow, getDragFilter, getDropFilter, getDropMode, getEditor, getFooterRows, getGenericDataView, getHeaderRows, getLazyDataView, getListDataView, getPageSize, getPropertySet, getSelectedItems, getSelectionModel, getSortOrder, getUniqueKeyProperty, getUniqueKeyProvider, initConnector, insertColumnLayer, isColumnReorderingAllowed, isDetailsVisible, isDetailsVisibleOnClick, isHeightByRows, isMultiSort, isRowsDraggable, isVerticalScrollingEnabled, onAttach, onDataProviderChange, onDetach, onEnabledStateChanged, prependFooterRow, prependHeaderRow, recalculateColumnWidths, removeAllColumns, removeColumn, removeColumnByKey, removeColumnLayer, removeColumns, removeThemeVariants, scrollToEnd, scrollToIndex, scrollToStart, select, setClassNameGenerator, setColumnKey, setColumnOrder, setColumnOrder, setColumnReorderingAllowed, setColumns, setDetailsVisible, setDetailsVisibleOnClick, setDragDataGenerator, setDragFilter, setDropFilter, setDropMode, setHeightByRows, setItemDetailsRenderer, setItems, setItems, setItems, setItems, setItems, setMultiSort, setPageSize, setRowsDraggable, setSelectionDragDetails, setSelectionMode, setSelectionModel, setSortableColumns, setUniqueKeyProperty, setUniqueKeyProvider, setVerticalScrollingEnabled, sort, updateSelectionModeOnClient
-
Methods inherited from class com.vaadin.flow.component.Component
addListener, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getLocale, getParent, getTranslation, getTranslation, getUI, hasListener, isTemplateMapped, isVisible, set, setElement, setId, setVisible
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.vaadin.flow.component.HasStyle
addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassName
-
Methods inherited from interface com.vaadin.flow.component.HasSize
getCssSize, getHeight, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getWidth, setHeight, setHeight, setHeightFull, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setSizeFull, setSizeUndefined, setWidth, setWidth, setWidthFull
-
Methods inherited from interface com.vaadin.flow.component.Focusable
addFocusShortcut, blur, focus, getTabIndex, setTabIndex
-
Methods inherited from interface com.vaadin.flow.component.BlurNotifier
addBlurListener
-
Methods inherited from interface com.vaadin.flow.component.FocusNotifier
addFocusListener
-
Methods inherited from interface com.vaadin.flow.component.HasEnabled
isEnabled, setEnabled
-
Methods inherited from interface com.vaadin.flow.component.HasElement
getElement
-
Methods inherited from interface com.vaadin.flow.component.HasTheme
addThemeName, addThemeNames, getThemeName, getThemeNames, hasThemeName, removeThemeName, removeThemeNames, setThemeName, setThemeName
-
Methods inherited from interface com.vaadin.flow.data.provider.HasListDataView
setItems, setItems
-
Methods inherited from interface com.vaadin.flow.data.provider.HasLazyDataView
setItems, setItems
-
Methods inherited from interface com.vaadin.flow.component.AttachNotifier
addAttachListener
-
Methods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListener
-
-
-
-
Method Detail
-
getFilter
public CrudFilter getFilter()
Gets the filter applied to this grid
Returns:
the filter
-
getDataProvider
public DataProvider<E,?> getDataProvider()
Gets the data provider set to the grid.
Overrides:
getDataProvider
in classGrid<E>
Returns:
the data provider of this grid, not
null
-
setDataProvider
public void setDataProvider(DataProvider<E,?> dataProvider) throws IllegalArgumentException
Sets a DataProvider<E, CrudFilter>
Overrides:
setDataProvider
in classGrid<E>
Parameters:
dataProvider
- aDataProvider
Throws:
IllegalArgumentException
- if the supplied data provider is not a DataProvider<E, CrudFilter>See Also:
-
-