ResourceDescriptor class
Descriptor for a resource exposed by a channel.
Constructors
- ResourceDescriptor({required String id, required String name, required String uri, required PayloadType payloadType, String? unit, bool readable = true, bool writable = false, bool subscribable = false})
-
const
-
ResourceDescriptor.fromJson(Map<
String, dynamic> json) -
Create from JSON.
factory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
Resource identifier.
final
- name → String
-
Human-readable name.
final
- payloadType → PayloadType
-
Payload data type.
final
- readable → bool
-
Whether this resource can be read.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- subscribable → bool
-
Whether this resource supports subscriptions.
final
- unit → String?
-
Unit of measurement.
final
- uri → String
-
Resource URI (e.g., io://deviceId/ch/1/waveform).
final
- writable → bool
-
Whether this resource can be written to.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> - Convert to JSON.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited