DefaultAssetPickerProvider class

Inheritance

Constructors

DefaultAssetPickerProvider({List<AssetEntity>? selectedAssets, RequestType requestType = RequestType.image, FilterOptionGroup? filterOptions, int maxAssets = 9, int pageSize = 80, int pathThumbSize = 80, Duration routeDuration = const Duration(milliseconds: 300)})
Call getAssetList with route duration when constructing. 构造时根据路由时长延时获取资源

Properties

currentAssets List<AssetEntity>
getter/setter pairinherited
currentAssetsListPage int
The current page for assets list. 当前加载的资源列表分页数
no setterinherited
currentPathEntity AssetPathEntity?
getter/setter pairinherited
filterOptions FilterOptionGroup?
Filter options for the picker. 选择器的筛选条件
final
hasAlbumsToDisplay bool
getter/setter pairinherited
hasAssetsToDisplay bool
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
hasMoreToLoad bool
Whether more assets are waiting for a load. 是否还有更多资源可以加载
no setterinherited
isAssetsEmpty bool
getter/setter pairinherited
isSelectedNotEmpty bool
选中资源是否为空
no setterinherited
isSwitchingPath bool
getter/setter pairinherited
maxAssets int
Maximum count for asset selection. 资源选择的最大数量
getter/setter pairinherited
maximumAssets int
no getterinherited
mounted bool
no setterinherited
pageSize int
Assets should be loaded per page. 资源选择的最大数量
finalinherited
pathEntityList Map<String, Tuple2<AssetPathEntity, Uint8List?>?>
no setterinherited
pathThumbSize int
Thumb size for path selector. 路径选择器中缩略图的大小
finalinherited
requestType RequestType
Request assets type. 请求的资源类型
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
selectedAssets List<AssetEntity>
getter/setter pairinherited
selectedDescriptions String
Descriptions for selected assets currently. 当前已被选中的资源的描述
no setterinherited
selectedMaximumAssets bool
是否已经选择了最大数量的资源
no setterinherited
totalAssetsCount int
getter/setter pairinherited
validPathThumbCount int
How many path has a valid thumb data. 当前有多少目录已经正常载入了缩略图
no setterinherited

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
clearAll() → void
inherited
dispose() → void
Clear all fields when dispose. 销毁时重置所有内容
inherited
getAssetList() Future<void>
Get assets list from current path entity. 从当前已选路径获取资源列表
getAssetPathList() Future<void>
Get assets path entities. 获取所有的资源路径
override
getAssetsFromEntity(int page, AssetPathEntity pathEntity) Future<void>
Get assets under the specific path entity. 获取指定路径下的资源
override
getFirstThumbFromPathEntity(AssetPathEntity pathEntity) Future<Uint8List?>
Get thumb data from the first asset under the specific path entity. 获取指定路径下的第一个资源的缩略数据
override
loadMoreAssets() Future<void>
Load more assets. 加载更多资源
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
Call all the registered listeners.
inherited
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that are notified when the object changes.
inherited
selectAsset(AssetEntity item) → void
Select asset. 选中资源
inherited
switchPath([AssetPathEntity? pathEntity]) Future<void>
Switch path entity. 切换路径
override
toString() String
A string representation of this object.
inherited
unSelectAsset(AssetEntity item) → void
Un-select asset. 取消选中资源
inherited

Operators

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