TModelDocs<DTO extends TWriteableId, MODEL extends TModel<DTO>> class

Constructors

TModelDocs({required TIdMapDef<MODEL> idMap, required TList<DTO, MODEL> list, required TModelBuilderDef<DTO, MODEL> modelBuilder})
const
TModelDocs.empty({required TModelBuilderDef<DTO, MODEL> modelBuilder})
factory
TModelDocs.fromDtos({required List<DTO> dtos, required TModelBuilderDef<DTO, MODEL> modelBuilder, required TSortOption? sort, required Set<TFilterInput<dynamic, TFilterOption, dynamic>>? filters})
factory

Properties

docs Iterable<MODEL>
no setter
filters Set<TFilterInput<dynamic, TFilterOption, dynamic>>?
no setter
hashCode int
The hash code for this object.
no setterinherited
ids Iterable<String>
no setter
isEmpty bool
no setter
isNotEmpty bool
no setter
length int
no setter
list List<MODEL>
no setter
modelBuilder TModelBuilderDef<DTO, MODEL>
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sort TSortOption?
no setter

Methods

dto(String? id) → DTO?
exists(String id) bool
findWhere(bool test(MODEL model)) Iterable<MODEL>
get(String? id) → MODEL?
listByIds(Iterable<String> ids) List<MODEL>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
remove(String id) → MODEL?
toString() String
A string representation of this object.
inherited
updateFilters(Set<TFilterInput<dynamic, TFilterOption, dynamic>> filters) → void
updateSort(TSortOption<MODEL> sort) → void
upsertDto(DTO newValue) → MODEL
upsertDtos(Iterable<DTO> newValues) List<MODEL>
upsertValue(MODEL newValue) → MODEL
upsertValues(Iterable<MODEL> newValues) List<MODEL>

Operators

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