SelectionUtil class

筛选组件工具类

Constructors

SelectionUtil()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

checkMaxSelectionCount(SelectionEntity entity) bool
entity 传入当前点击的 Item !!! 在设置 isSelected = true之前进行 check。 返回 true 符合条件,false 不符合条件
currentSelectListForEntity(SelectionEntity entity) List<SelectionEntity>
返回状态为选中的子节点
getCurrentListIndex(SelectionEntity? currentItem) int
确定当前 Item 在第几层级
getFilledCustomInputItem(List<SelectionEntity> list) SelectionEntity?
判断列表中是否有range类型
getTotalLevel(SelectionEntity entity) int
筛选项最多不超过三层,故直接写代码判断,本质为深度优先搜索。
hasRangeItem(List<SelectionEntity> list) bool
判断列表中是否有range类型
processBrotherItemSelectStatus(SelectionEntity selectionEntity) → void
处理兄弟结点为未选中状态,将自己置为选中状态
resetSelectionDatas(SelectionEntity entity) → void
设置数据为未选中状态