MhItemsView<T> class
This is the Main class and Widget of MhItemsView
MhItemsView can display ItemsView, DataTable, TreeView, TreeListView
It supports most common scenarios like:
- Drag and drop
- Reorder via drag and drop
- filtering the data
- Millions of rows with virtualizing
- Inline Edit, multiline edit
- and much more.
For Documentation see: https://flutter.mahop.net and https://flutterdemo.mahop.net
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- MhItemsView
Constructors
-
MhItemsView({Key? key, required List<
T> itemsSource, List<MhItemsViewColumnDef< ? columnDefs, MhItemsViewSettings<T> >T> ? settings, MhItemsViewTheme? theme, MhItemsViewTheme? themeDark, String debugName = "noName"})
Properties
-
columnDefs
→ List<
MhItemsViewColumnDef< ?T> > -
final
- debugName → String
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
itemsSource
→ List<
T> -
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
settings
→ MhItemsViewSettings<
T> ? -
final
- theme → MhItemsViewTheme?
-
final
- themeDark → MhItemsViewTheme?
-
final
Methods
-
addFilter(
bool displayItem(T item)) → dynamic - adds a Filter and refreshes the MhItemsView multiple filters are combined with logical AND use only one (complex) filter function to have full control
-
addFilterDef(
MhItemsViewFilterDef< T> filterDef) → dynamic - adds a FilterDefinition (if not already present) and refreshes the MhItemsView multiple filters are combined with logical AND
-
addSortDefinition(
MhItemsViewSortDef< T> sortDef) → dynamic - Adds a sort definition or pushes it to the end if already present and refreshes the MhItemsView
-
addSortFunction(
{required Object getSortValue(T item), MhItemsViewSortDirections sortDirection = MhItemsViewSortDirections.asc}) → dynamic - Builds a default MhItemsViewSortDef with the given function and refreshes the MhItemsView
-
clearFilter(
) → dynamic - removes all filters and refreshes the MhItemsView
-
clearSortDefinitions(
) → dynamic - Removes all sort definitions and refreshes the MhItemsView
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< MhItemsView< T> > -
Creates the mutable state for this widget at a given location in the tree.
override
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
getColumnLayoutJson(
) → String -
jumpTo(
{required T item, bool blink = true, bool centerItem = true, bool onlyIfNotVisible = false}) → dynamic -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
refreshFilter(
) → dynamic - Executes the filter again over all items and refreshes the MhItemsView call this function for example if the user changed the filter value
-
refreshSorting(
) → dynamic - Executes the sort definitions and refreshes the MhItemsView
-
setColumnLayoutFromJson(
{required String jsonStr}) → dynamic -
setFilter(
bool displayItem(T item)) → dynamic - clears the current filter function(s) and add the given one as the only filter and refreshes the MhItemsView
-
setItemsSource(
List< T> itemsSource) → void -
setSortDefinition(
{required Object getSortValue(T item), MhItemsViewSortDirections sortDirection = MhItemsViewSortDirections.asc}) → dynamic - Removes all sort definitions and refreshes the MhItemsView
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited