DataRequestLabel constructor
DataRequestLabel(
- String kind, {
- required String type,
- String? id,
- String? requestId,
- DataModelMixin<
DataModelMixin> ? model, - DataRequestLabel? withParent,
Implementation
DataRequestLabel(
String kind, {
required this.type,
this.id,
String? requestId,
this.model,
DataRequestLabel? withParent,
}) : kind = kind.trim() {
assert(!type.contains('#'));
if (id != null) {
assert(!id!.contains('#'));
}
if (requestId != null) {
assert(!requestId.contains('@'));
}
_requestIds.add(requestId ?? DataHelpers.generateShortKey());
if (withParent != null) {
_requestIds.addAll(withParent._requestIds);
}
}