DeviceMetadata class
Represents the configuration data for a device.
Constructors
- DeviceMetadata({required String name, required DeviceArchetype archetype})
- Creates a DeviceMetadata object.
- DeviceMetadata.empty()
- Creates an empty DeviceMetadata object.
-
DeviceMetadata.fromJson(Map<
String, dynamic> dataMap) -
Creates a DeviceMetadata object from the JSON response to a GET request.
factory
Properties
- archetype ↔ DeviceArchetype
-
Device archetype.
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setteroverride
- name ↔ String
-
Human readable name of a resource.
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
copyWith(
{String? name, DeviceArchetype? archetype, bool copyOriginalValues = true}) → DeviceMetadata - Returns a copy of this object with its field values replaced by the ones provided to this method.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
refreshOriginals(
) → void - Called after a successful PUT request, this method refreshed the "original" data in this object.
-
toJson(
{OptimizeFor optimizeFor = OptimizeFor.put}) → Map< String, dynamic> - Converts this object into JSON format.
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override