Skip to content
This repository has been archived by the owner on Sep 12, 2024. It is now read-only.
github-actions[bot] edited this page Aug 11, 2023 · 51 revisions

Class: Scene

Hierarchy

Table of contents

Constructors

Properties

Accessors

Methods

Constructors

constructor

new Scene(bridge, data)

Parameters

Name Type
bridge Hue
data SceneGet & { metadata: { archetype: ArcheType ; name: string } }

Inherited from

NamedResource.constructor

Defined in

src/structures/NamedResource.ts:15

Properties

data

data: SceneGet & { metadata: { archetype: ArcheType ; name: string } }

Inherited from

NamedResource.data

Defined in

src/structures/NamedResource.ts:13


hue

Readonly hue: Hue

Inherited from

NamedResource.hue

Defined in

src/structures/Resource.ts:51


type

type: ResourceType = ResourceType.Scene

Overrides

NamedResource.type

Defined in

src/structures/Scene.ts:52

Accessors

actions

get actions(): SceneAction[]

Returns

SceneAction[]

Defined in

src/structures/Scene.ts:62


archeType

get archeType(): ArcheType

Returns

ArcheType

Inherited from

NamedResource.archeType

Defined in

src/structures/NamedResource.ts:24


groupId

get groupId(): string

Returns

string

Defined in

src/structures/Scene.ts:58


id

get id(): string

Returns

string

Inherited from

NamedResource.id

Defined in

src/structures/Resource.ts:56


identifier

get identifier(): ResourceIdentifier<ResourceType>

Returns

ResourceIdentifier<ResourceType>

Inherited from

NamedResource.identifier

Defined in

src/structures/Resource.ts:60


manager

get manager(): SceneManager

Returns

SceneManager

Overrides

NamedResource.manager

Defined in

src/structures/Scene.ts:54


name

get name(): string

Returns

string

Inherited from

NamedResource.name

Defined in

src/structures/NamedResource.ts:20


speed

get speed(): number

Returns

number

Defined in

src/structures/Scene.ts:77

Methods

_clone

_clone(): Scene

Returns

Scene

Inherited from

NamedResource._clone

Defined in

src/structures/Resource.ts:77


_patch

_patch(data): void

Parameters

Name Type
data Partial<SceneGet>

Returns

void

Inherited from

NamedResource._patch

Defined in

src/structures/Resource.ts:73


_update

_update(data): Scene

Parameters

Name Type
data Partial<SceneGet>

Returns

Scene

Inherited from

NamedResource._update

Defined in

src/structures/Resource.ts:81


actionFor

actionFor(id): undefined | SceneAction

Parameters

Name Type
id string

Returns

undefined | SceneAction

Defined in

src/structures/Scene.ts:81


createActionFor

createActionFor(id, options): Promise<void>

Parameters

Name Type
id string
options Omit<SceneAction, "id">

Returns

Promise<void>

Defined in

src/structures/Scene.ts:89


delete

delete(): Promise<void>

Returns

Promise<void>

Defined in

src/structures/Scene.ts:112


edit

edit(options): Promise<void>

Parameters

Name Type
options SceneEditOptions

Returns

Promise<void>

Overrides

NamedResource.edit

Defined in

src/structures/Scene.ts:108


editActionFor

editActionFor(id, options): Promise<void>

Parameters

Name Type
id string
options Omit<SceneAction, "id">

Returns

Promise<void>

Defined in

src/structures/Scene.ts:95


isType

isType<T>(type): this is NarrowResource<T>

Type parameters

Name Type
T extends ResourceType

Parameters

Name Type
type T

Returns

this is NarrowResource<T>

Inherited from

NamedResource.isType

Defined in

src/structures/Resource.ts:69


recall

recall(options?): Promise<void>

Parameters

Name Type
options? Object
options.action? "active" | "dynamic_palette"
options.brightness? number
options.duration? number

Returns

Promise<void>

Defined in

src/structures/Scene.ts:85


setActions

setActions(actions): Promise<void>

Parameters

Name Type
actions SceneAction[]

Returns

Promise<void>

Defined in

src/structures/Scene.ts:104


setArcheType

setArcheType(archeType): Promise<void>

Parameters

Name Type
archeType ArcheType

Returns

Promise<void>

Inherited from

NamedResource.setArcheType

Defined in

src/structures/NamedResource.ts:32


setName

setName(name): Promise<void>

Parameters

Name Type
name string

Returns

Promise<void>

Inherited from

NamedResource.setName

Defined in

src/structures/NamedResource.ts:28

hue.ts

Clone this wiki locally