ReferencedModelEqualityMixin<T extends ReferencedModel> mixin
A mixin on ReferencedModel that implements EquatableMixin
to identify
the model by id an ref.
- Implemented types
- Available extensions
Properties
- $className → String
-
The runtime type of this class as a String.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String?
-
The unique identifier for the document, serving as its primary key.
finalinherited
- id$ → String
-
Returns the value of the id field.
If the field is nullable, the return value may be null; otherwise, it
will always return a non-null value.
no setterinherited
-
props
→ List<
Object?> -
The list of properties that will be used to determine whether
two instances are equal.
no setter
- ref → DataRefModel?
-
A reference to this model that indicates the document's location within the database.
finalinherited
- ref$ → DataRefModel
-
Returns the value of the ref field.
If the field is nullable, the return value may be null; otherwise, it
will always return a non-null value.
no setterinherited
-
rootData
→ Map<
String, dynamic> -
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stringify → bool?
-
If set to
true
, the toString method will be overridden to output this instance's props.no setter
Methods
-
copyWith(
{String? id, DataRefModel? ref}) → ReferencedModel -
Available on ReferencedModel, provided by the ReferencedModelX extension
Creates a copy of this instance, replacing the specified fields. -
copyWithout(
{bool id = true, bool ref = true}) → ReferencedModel -
Available on ReferencedModel, provided by the ReferencedModelX extension
Creates a copy of this instance, removing the specified fields. -
equals(
dynamic other) → bool -
Compares the BaseModel with another BaseModel using the
DeepCollectionEquality
and returnstrue
if they are equal.inherited -
mergeWith(
BaseModel? other, {bool deepMerge = false}) → ReferencedModel -
Available on ReferencedModel, provided by the ReferencedModelX extension
Creates a copy of this instance, merging another model's fields into this model's fields. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
sortedJson(
{bool includeNulls = false}) → Map< String, dynamic> -
Returns a Json i.e.
Map<String, dynamic>
representation of the BaseModel, with the keys sorted alphabetically.inherited -
toJson(
{bool includeNulls = false}) → Map< String, dynamic> -
Returns a Json i.e.
Map<String, dynamic>
representation of the BaseModel.inherited -
toJsonString(
) → String -
Returns a JSON string representation of the BaseModel.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
toUrl(
) → Uri -
Converts the current BaseModel to a Uri that can be used as a
distinct identifier. The model must not be too large to avoid exceeding
the maximum length of a URL.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited