Light class abstract

Constructors

Light([dynamic updates(LightBuilder b)])
factory
Light.fromJson(Map json, {int? id})
factory

Properties

colors → HueColor?
get the current color of the light in all possible means by the bridge
no setter
hashCode int
The hash code for this object.
no setterinherited
id int?
id of the light in the bridge
no setter
luminaireUniqueId String?
As of 1.9. Unique ID of the luminaire the light is a part of in the format: AA:BB:CC:DD-XX-YY. AA:BB:, ... represents the hex of the luminaireid, XX the lightsource position (incremental but may contain gaps) and YY the lightpoint position (index of light in luminaire group). A gap in the lightpoint position indicates an incomplete luminaire (light search required to discover missing light points in this case).
no setter
manufacturerName String?
As of 1.7. The manufacturer name.
no setter
model → LightModel?
no setter
modelId String?
The hardware model of the light.
no setter
name String?
A unique, editable name given to the light.
no setter
productName String
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
state LightState?
no setter
swVersion String?
An identifier for the software version running on the light.
no setter
type String?
A fixed name describing the type of light e.g. “Extended color light”.
no setter
uniqueId String?
As of 1.4. Unique id of the device. The MAC address of the device with a unique endpoint id in the form: AA:BB:CC:DD:EE:FF:00:11-XX
no setter

Methods

changeColor({num red = 0, num green = 0, num blue = 0}) Light
change the color of the light on the bridge with rgb values ranging from 0 to 1
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
rebuild(dynamic updates(LightBuilder)) Light
Rebuilds the instance.
inherited
toBridgeObject({String? action}) Map
toBuilder() LightBuilder
Converts the instance to a builder B.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

serializer → Serializer<Light>
no setter