ItemWithId class

A combination of ItemId and Item for create/update operations.

This is a convenience class that bundles identification and data together for operations that need both.

Constructors

ItemWithId({required String id, required String collection, required JsonObject item})
Creates a new ItemWithId with the given id, collection, and item data.

Properties

collection → String
The collection containing this item.
final
hashCode → int
The hash code for this object.
no setteroverride
id → String
The unique identifier of the item.
final
item → JsonObject
The item's data payload.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

copyWith({String? id, String? collection, JsonObject? item}) → ItemWithId
Creates a copy of this ItemWithId with optionally modified fields.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toItem() → Item
Converts this to an Item.
toItemId() → ItemId
Converts this to an ItemId.
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
override