ReferencedModel class

Generated class for _ReferencedModel.

Inheritance
Available extensions

Constructors

ReferencedModel.new({required String? id, required DataRefModel? ref})
Constructs a new instance of ReferencedModel from optional and required parameters.
const
ReferencedModel.assertRequired({String? id, DataRefModel? ref})
Constructs a new instance of ReferencedModel, and asserts that all required parameters are not null.
factory
ReferencedModel.from(BaseModel another)
Constructs a new instance of ReferencedModel, from the fields of another instance. Throws if the conversion fails.
factory
ReferencedModel.fromJson(Map<String, dynamic>? json)
Constructs a new instance of ReferencedModel, from json, which must be a valid JSON object. Throws if the conversion fails.
factory
ReferencedModel.fromJsonString(String jsonString)
Constructs a new instance of ReferencedModel, from jsonString, which must be a valid JSON String. Throws if the conversion fails.
factory
ReferencedModel.fromUri(Uri? uri)
Constructs a new instance of ReferencedModel, from the query parameters of uri. Throws if the conversion fails.
factory
ReferencedModel.of(ReferencedModel another)
Constructs a new instance of ReferencedModel, from the fields of another instance. Throws if the conversion fails.
factory
ReferencedModel.optional({String? id, DataRefModel? ref})
Construcs a new instance of ReferencedModel, forcing all parameters to be optional.
const

Properties

$className String
The runtime type of this class as a String.
no setteroverride
hashCode int
The hash code for this object.
no setterinherited
id String?
The unique identifier for the document, serving as its primary key.
final
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 setter
props List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setterinherited
ref DataRefModel?
A reference to this model that indicates the document's location within the database.
final
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 setter
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 setterinherited

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 returns true 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.
override
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

Static Methods

fromJsonOrNull(Map<String, dynamic>? json) ReferencedModel?
Constructs a new instance of ReferencedModel, from json, which must be a valid JSON object. Returns null if json is null or if the conversion fails.
fromJsonStringOrNull(String? jsonString) ReferencedModel?
Constructs a new instance of ReferencedModel, from jsonString, which must be a valid JSON String. Returns null if jsonString is null or if the conversion fails.
override
fromOrNull(BaseModel? another) ReferencedModel?
Constructs a new instance of ReferencedModel, from the fields of another instance. Returns null if another is null or if the conversion fails.
fromUriOrNull(Uri? uri) ReferencedModel?
Constructs a new instance of ReferencedModel, from the query parameters of uri. Returns null if uri is null or if the conversion fails.
ofOrNull(ReferencedModel? other) ReferencedModel?
Constructs a new instance of ReferencedModel, from the fields of another instance. Returns null if another is null or if the conversion fails.

Constants

CLASS_NAME → const String
The runtime type of this class as a String.