2
0
mirror of https://github.com/esiur/esiur-dart.git synced 2025-12-17 01:10:25 +00:00
This commit is contained in:
2024-06-22 03:50:54 +03:00
parent 8a30c92e19
commit 26794f08e7
32 changed files with 1508 additions and 595 deletions

View File

@@ -510,6 +510,11 @@ class Warehouse {
return _factory[type]?.arrayCreator.call() as List<T>;
}
static Map<T, dynamic> createMap<T>(Type keyType) {
return _factory[keyType]?.mapCreator.call() as Map<T, dynamic>;
}
static AsyncReply<T> newResource<T extends IResource>(String name,
[IStore? store = null,
IResource? parent = null,
@@ -759,6 +764,8 @@ class Warehouse {
RepresentationType(RepresentationTypeIdentifier.Int64, false)))
..addAll(_getTypeEntries<bool>(() => false,
RepresentationType(RepresentationTypeIdentifier.Bool, false)))
..addAll(_getTypeEntries<Float32>(() => 0.0,
RepresentationType(RepresentationTypeIdentifier.Float64, false)))
..addAll(_getTypeEntries<double>(() => 0.0,
RepresentationType(RepresentationTypeIdentifier.Float64, false)))
..addAll(_getTypeEntries<String>(() => "",