This is the default server implementation of DeviceEnergyManagementBehavior.

The Matter specification requires the DeviceEnergyManagement cluster to support features we do not enable by default. You should use DeviceEnergyManagementServer.with to specialize the class for the features your implementation supports.

Hierarchy (view full)

Constructors

Properties

[reference]: Datasource<StateType>
agent: Agent
cluster: never

The implemented cluster.

context: ActionContext
endpoint: Endpoint<Empty>
events: EventEmitter & Omit<ClusterEvents<Of<{
    attributes: {};
    commands: {};
    events: {};
    id: 0;
    name: "Unknown";
    revision: 0;
}>, typeof ClusterBehavior>, never> & {
    absMaxPower$Changing: ClusterEvents.AttributeObservable<Attribute<number | bigint, any>>;
    absMinPower$Changing: ClusterEvents.AttributeObservable<Attribute<number | bigint, any>>;
    esaCanGenerate$Changing: ClusterEvents.AttributeObservable<FixedAttribute<boolean, any>>;
    esaState$Changing: ClusterEvents.AttributeObservable<Attribute<DeviceEnergyManagement.EsaState, any>>;
    esaType$Changing: ClusterEvents.AttributeObservable<FixedAttribute<DeviceEnergyManagement.EsaType, any>>;
} & {} & {
    absMaxPower$Changed: ClusterEvents.AttributeObservable<Attribute<number | bigint, any>>;
    absMinPower$Changed: ClusterEvents.AttributeObservable<Attribute<number | bigint, any>>;
    esaCanGenerate$Changed: ClusterEvents.AttributeObservable<FixedAttribute<boolean, any>>;
    esaState$Changed: ClusterEvents.AttributeObservable<Attribute<DeviceEnergyManagement.EsaState, any>>;
    esaType$Changed: ClusterEvents.AttributeObservable<FixedAttribute<DeviceEnergyManagement.EsaType, any>>;
} & {} & {} & {}

Access the behavior's events.

features: TypeFromBitSchema<{}> & TypeFromBitSchema<{
    constraintBasedAdjustment: BitFlag;
    forecastAdjustment: BitFlag;
    pausable: BitFlag;
    powerAdjustment: BitFlag;
    powerForecastReporting: BitFlag;
    startTimeAdjustment: BitFlag;
    stateForecastReporting: BitFlag;
}>

Supported features as a flag object.

session: SecureSession
state: Omit<ClusterState.Type<Of<{
    attributes: {};
    commands: {};
    events: {};
    id: 0;
    name: "Unknown";
    revision: 0;
}>, typeof ClusterBehavior>, never> & {
    absMaxPower: number | bigint;
    absMinPower: number | bigint;
    esaState: DeviceEnergyManagement.EsaState;
} & {} & {
    esaCanGenerate: boolean;
    esaType: DeviceEnergyManagement.EsaType;
} & {}

Access the behavior's state.

cluster: Of<{
    attributes: {
        absMaxPower: Attribute<number | bigint, any>;
        absMinPower: Attribute<number | bigint, any>;
        esaCanGenerate: FixedAttribute<boolean, any>;
        esaState: Attribute<DeviceEnergyManagement.EsaState, any>;
        esaType: FixedAttribute<DeviceEnergyManagement.EsaType, any>;
    };
    extensions: readonly [{
        component: {
            attributes: {
                powerAdjustmentCapability: Attribute<null | TypeFromFields<{
                    maxDuration: ...;
                    maxPower: ...;
                    minDuration: ...;
                    minPower: ...;
                }>[], any>;
            };
            commands: {
                cancelPowerAdjustRequest: Command<void, void, any>;
                powerAdjustRequest: Command<TypeFromFields<{
                    cause: FieldType<DeviceEnergyManagement.AdjustmentCause>;
                    duration: FieldType<number>;
                    power: FieldType<(...) | (...)>;
                }>, void, any>;
            };
            events: {
                powerAdjustEnd: Event<TypeFromFields<{
                    cause: FieldType<DeviceEnergyManagement.Cause>;
                    duration: FieldType<number>;
                    energyUse: FieldType<(...) | (...)>;
                }>, any>;
                powerAdjustStart: Event<void, any>;
            };
        };
        flags: {
            powerAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                forecast: Attribute<null | TypeFromFields<{
                    activeSlotNumber: FieldType<(...)>;
                    earliestStartTime: OptionalFieldType<(...)>;
                    endTime: FieldType<(...)>;
                    forecastId: FieldType<(...)>;
                    forecastUpdateReason: FieldType<(...)>;
                    isPauseable: FieldType<(...)>;
                    latestEndTime: OptionalFieldType<(...)>;
                    slots: FieldType<(...)>;
                    startTime: FieldType<(...)>;
                }>, any>;
            };
        };
        flags: {
            powerForecastReporting: true;
        };
    }, {
        component: {
            attributes: {
                forecast: Attribute<null | TypeFromFields<{
                    activeSlotNumber: FieldType<(...)>;
                    earliestStartTime: OptionalFieldType<(...)>;
                    endTime: FieldType<(...)>;
                    forecastId: FieldType<(...)>;
                    forecastUpdateReason: FieldType<(...)>;
                    isPauseable: FieldType<(...)>;
                    latestEndTime: OptionalFieldType<(...)>;
                    slots: FieldType<(...)>;
                    startTime: FieldType<(...)>;
                }>, any>;
            };
        };
        flags: {
            stateForecastReporting: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            powerAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            startTimeAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            pausable: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            forecastAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            constraintBasedAdjustment: true;
        };
    }, {
        component: {
            commands: {
                pauseRequest: Command<TypeFromFields<{
                    cause: FieldType<DeviceEnergyManagement.AdjustmentCause>;
                    duration: FieldType<number>;
                }>, void, any>;
                resumeRequest: Command<void, void, any>;
            };
            events: {
                paused: Event<void, any>;
                resumed: Event<TypeFromFields<{
                    cause: FieldType<DeviceEnergyManagement.Cause>;
                }>, any>;
            };
        };
        flags: {
            pausable: true;
        };
    }, {
        component: {
            commands: {
                startTimeAdjustRequest: Command<TypeFromFields<{
                    cause: FieldType<DeviceEnergyManagement.AdjustmentCause>;
                    requestedStartTime: FieldType<number>;
                }>, void, any>;
            };
        };
        flags: {
            startTimeAdjustment: true;
        };
    }, {
        component: {
            commands: {
                modifyForecastRequest: Command<TypeFromFields<{
                    cause: FieldType<DeviceEnergyManagement.AdjustmentCause>;
                    forecastId: FieldType<number>;
                    slotAdjustments: FieldType<(...)[]>;
                }>, void, any>;
            };
        };
        flags: {
            forecastAdjustment: true;
        };
    }, {
        component: {
            commands: {
                requestConstraintBasedForecast: Command<TypeFromFields<{
                    cause: FieldType<DeviceEnergyManagement.AdjustmentCause>;
                    constraints: FieldType<(...)[]>;
                }>, void, any>;
            };
        };
        flags: {
            constraintBasedAdjustment: true;
        };
    }, {
        component: {
            commands: {
                cancelRequest: Command<void, void, any>;
            };
        };
        flags: {
            startTimeAdjustment: true;
        };
    }, {
        component: {
            commands: {
                cancelRequest: Command<void, void, any>;
            };
        };
        flags: {
            forecastAdjustment: true;
        };
    }, {
        component: {
            commands: {
                cancelRequest: Command<void, void, any>;
            };
        };
        flags: {
            constraintBasedAdjustment: true;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            startTimeAdjustment: true;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            pausable: true;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            forecastAdjustment: true;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            constraintBasedAdjustment: true;
            feature: false;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            powerForecastReporting: false;
            startTimeAdjustment: true;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            pausable: true;
            powerForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            forecastAdjustment: true;
            powerForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            constraintBasedAdjustment: true;
            feature: false;
            powerForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            constraintBasedAdjustment: false;
            forecastAdjustment: false;
            pausable: false;
            powerAdjustment: false;
            powerForecastReporting: false;
            startTimeAdjustment: false;
            stateForecastReporting: false;
        };
    }];
    features: {
        constraintBasedAdjustment: BitFlag;
        forecastAdjustment: BitFlag;
        pausable: BitFlag;
        powerAdjustment: BitFlag;
        powerForecastReporting: BitFlag;
        startTimeAdjustment: BitFlag;
        stateForecastReporting: BitFlag;
    };
    id: 152;
    name: "DeviceEnergyManagement";
    revision: 3;
}>

Base cluster state include all attribute values but may be extended by subclasses.

defaults: ClusterState.Type<Of<{
    attributes: {
        absMaxPower: Attribute<number | bigint, any>;
        absMinPower: Attribute<number | bigint, any>;
        esaCanGenerate: FixedAttribute<boolean, any>;
        esaState: Attribute<DeviceEnergyManagement.EsaState, any>;
        esaType: FixedAttribute<DeviceEnergyManagement.EsaType, any>;
    };
    extensions: readonly [{
        component: {
            attributes: {
                powerAdjustmentCapability: Attribute<null | TypeFromFields<(...)>[], any>;
            };
            commands: {
                cancelPowerAdjustRequest: Command<void, void, any>;
                powerAdjustRequest: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    duration: FieldType<(...)>;
                    power: FieldType<(...)>;
                }>, void, any>;
            };
            events: {
                powerAdjustEnd: Event<TypeFromFields<{
                    cause: FieldType<(...)>;
                    duration: FieldType<(...)>;
                    energyUse: FieldType<(...)>;
                }>, any>;
                powerAdjustStart: Event<void, any>;
            };
        };
        flags: {
            powerAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                forecast: Attribute<null | TypeFromFields<{
                    activeSlotNumber: ...;
                    earliestStartTime: ...;
                    endTime: ...;
                    forecastId: ...;
                    forecastUpdateReason: ...;
                    isPauseable: ...;
                    latestEndTime: ...;
                    slots: ...;
                    startTime: ...;
                }>, any>;
            };
        };
        flags: {
            powerForecastReporting: true;
        };
    }, {
        component: {
            attributes: {
                forecast: Attribute<null | TypeFromFields<{
                    activeSlotNumber: ...;
                    earliestStartTime: ...;
                    endTime: ...;
                    forecastId: ...;
                    forecastUpdateReason: ...;
                    isPauseable: ...;
                    latestEndTime: ...;
                    slots: ...;
                    startTime: ...;
                }>, any>;
            };
        };
        flags: {
            stateForecastReporting: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            powerAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            startTimeAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            pausable: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            forecastAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            constraintBasedAdjustment: true;
        };
    }, {
        component: {
            commands: {
                pauseRequest: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    duration: FieldType<(...)>;
                }>, void, any>;
                resumeRequest: Command<void, void, any>;
            };
            events: {
                paused: Event<void, any>;
                resumed: Event<TypeFromFields<{
                    cause: FieldType<(...)>;
                }>, any>;
            };
        };
        flags: {
            pausable: true;
        };
    }, {
        component: {
            commands: {
                startTimeAdjustRequest: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    requestedStartTime: FieldType<(...)>;
                }>, void, any>;
            };
        };
        flags: {
            startTimeAdjustment: true;
        };
    }, {
        component: {
            commands: {
                modifyForecastRequest: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    forecastId: FieldType<(...)>;
                    slotAdjustments: FieldType<(...)>;
                }>, void, any>;
            };
        };
        flags: {
            forecastAdjustment: true;
        };
    }, {
        component: {
            commands: {
                requestConstraintBasedForecast: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    constraints: FieldType<(...)>;
                }>, void, any>;
            };
        };
        flags: {
            constraintBasedAdjustment: true;
        };
    }, {
        component: {
            commands: {
                cancelRequest: Command<void, void, any>;
            };
        };
        flags: {
            startTimeAdjustment: true;
        };
    }, {
        component: {
            commands: {
                cancelRequest: Command<void, void, any>;
            };
        };
        flags: {
            forecastAdjustment: true;
        };
    }, {
        component: {
            commands: {
                cancelRequest: Command<void, void, any>;
            };
        };
        flags: {
            constraintBasedAdjustment: true;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            startTimeAdjustment: true;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            pausable: true;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            forecastAdjustment: true;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            constraintBasedAdjustment: true;
            feature: false;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            powerForecastReporting: false;
            startTimeAdjustment: true;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            pausable: true;
            powerForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            forecastAdjustment: true;
            powerForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            constraintBasedAdjustment: true;
            feature: false;
            powerForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            constraintBasedAdjustment: false;
            forecastAdjustment: false;
            pausable: false;
            powerAdjustment: false;
            powerForecastReporting: false;
            startTimeAdjustment: false;
            stateForecastReporting: false;
        };
    }];
    features: {
        constraintBasedAdjustment: BitFlag;
        forecastAdjustment: BitFlag;
        pausable: BitFlag;
        powerAdjustment: BitFlag;
        powerForecastReporting: BitFlag;
        startTimeAdjustment: BitFlag;
        stateForecastReporting: BitFlag;
    };
    id: 152;
    name: "DeviceEnergyManagement";
    revision: 3;
}>, Type<Of<{
    attributes: {};
    commands: {};
    events: {};
    id: 0;
    name: "Unknown";
    revision: 0;
}>, typeof ClusterBehavior, DeviceEnergyManagementInterface>>
dependencies?: Iterable<Type, any, any>
early: boolean
Events: ClusterEvents.Type<Of<{
    attributes: {
        absMaxPower: Attribute<number | bigint, any>;
        absMinPower: Attribute<number | bigint, any>;
        esaCanGenerate: FixedAttribute<boolean, any>;
        esaState: Attribute<DeviceEnergyManagement.EsaState, any>;
        esaType: FixedAttribute<DeviceEnergyManagement.EsaType, any>;
    };
    extensions: readonly [{
        component: {
            attributes: {
                powerAdjustmentCapability: Attribute<null | TypeFromFields<(...)>[], any>;
            };
            commands: {
                cancelPowerAdjustRequest: Command<void, void, any>;
                powerAdjustRequest: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    duration: FieldType<(...)>;
                    power: FieldType<(...)>;
                }>, void, any>;
            };
            events: {
                powerAdjustEnd: Event<TypeFromFields<{
                    cause: FieldType<(...)>;
                    duration: FieldType<(...)>;
                    energyUse: FieldType<(...)>;
                }>, any>;
                powerAdjustStart: Event<void, any>;
            };
        };
        flags: {
            powerAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                forecast: Attribute<null | TypeFromFields<{
                    activeSlotNumber: ...;
                    earliestStartTime: ...;
                    endTime: ...;
                    forecastId: ...;
                    forecastUpdateReason: ...;
                    isPauseable: ...;
                    latestEndTime: ...;
                    slots: ...;
                    startTime: ...;
                }>, any>;
            };
        };
        flags: {
            powerForecastReporting: true;
        };
    }, {
        component: {
            attributes: {
                forecast: Attribute<null | TypeFromFields<{
                    activeSlotNumber: ...;
                    earliestStartTime: ...;
                    endTime: ...;
                    forecastId: ...;
                    forecastUpdateReason: ...;
                    isPauseable: ...;
                    latestEndTime: ...;
                    slots: ...;
                    startTime: ...;
                }>, any>;
            };
        };
        flags: {
            stateForecastReporting: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            powerAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            startTimeAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            pausable: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            forecastAdjustment: true;
        };
    }, {
        component: {
            attributes: {
                optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
            };
        };
        flags: {
            constraintBasedAdjustment: true;
        };
    }, {
        component: {
            commands: {
                pauseRequest: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    duration: FieldType<(...)>;
                }>, void, any>;
                resumeRequest: Command<void, void, any>;
            };
            events: {
                paused: Event<void, any>;
                resumed: Event<TypeFromFields<{
                    cause: FieldType<(...)>;
                }>, any>;
            };
        };
        flags: {
            pausable: true;
        };
    }, {
        component: {
            commands: {
                startTimeAdjustRequest: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    requestedStartTime: FieldType<(...)>;
                }>, void, any>;
            };
        };
        flags: {
            startTimeAdjustment: true;
        };
    }, {
        component: {
            commands: {
                modifyForecastRequest: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    forecastId: FieldType<(...)>;
                    slotAdjustments: FieldType<(...)>;
                }>, void, any>;
            };
        };
        flags: {
            forecastAdjustment: true;
        };
    }, {
        component: {
            commands: {
                requestConstraintBasedForecast: Command<TypeFromFields<{
                    cause: FieldType<(...)>;
                    constraints: FieldType<(...)>;
                }>, void, any>;
            };
        };
        flags: {
            constraintBasedAdjustment: true;
        };
    }, {
        component: {
            commands: {
                cancelRequest: Command<void, void, any>;
            };
        };
        flags: {
            startTimeAdjustment: true;
        };
    }, {
        component: {
            commands: {
                cancelRequest: Command<void, void, any>;
            };
        };
        flags: {
            forecastAdjustment: true;
        };
    }, {
        component: {
            commands: {
                cancelRequest: Command<void, void, any>;
            };
        };
        flags: {
            constraintBasedAdjustment: true;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            startTimeAdjustment: true;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            pausable: true;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            forecastAdjustment: true;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            constraintBasedAdjustment: true;
            feature: false;
            stateForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            powerForecastReporting: false;
            startTimeAdjustment: true;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            pausable: true;
            powerForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            feature: false;
            forecastAdjustment: true;
            powerForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            constraintBasedAdjustment: true;
            feature: false;
            powerForecastReporting: false;
        };
    }, {
        component: false;
        flags: {
            constraintBasedAdjustment: false;
            forecastAdjustment: false;
            pausable: false;
            powerAdjustment: false;
            powerForecastReporting: false;
            startTimeAdjustment: false;
            stateForecastReporting: false;
        };
    }];
    features: {
        constraintBasedAdjustment: BitFlag;
        forecastAdjustment: BitFlag;
        pausable: BitFlag;
        powerAdjustment: BitFlag;
        powerForecastReporting: BitFlag;
        startTimeAdjustment: BitFlag;
        stateForecastReporting: BitFlag;
    };
    id: 152;
    name: "DeviceEnergyManagement";
    revision: 3;
}>, Type<Of<{
    attributes: {};
    commands: {};
    events: {};
    id: 0;
    name: "Unknown";
    revision: 0;
}>, typeof ClusterBehavior, DeviceEnergyManagementInterface>>
ExtensionInterface: {}
id

The behavior ID for ClusterBehaviors is the name of the cluster.

Internal: (new () => {})

Type declaration

    • new (): {}
    • Implementation of internal state. Subclasses may override to extend.

      Returns {}

    name: string
    schema?: Schema
    State: (new () => ClusterState.Type<Of<{
        attributes: {
            absMaxPower: Attribute<number | bigint, any>;
            absMinPower: Attribute<number | bigint, any>;
            esaCanGenerate: FixedAttribute<boolean, any>;
            esaState: Attribute<DeviceEnergyManagement.EsaState, any>;
            esaType: FixedAttribute<DeviceEnergyManagement.EsaType, any>;
        };
        extensions: readonly [{
            component: {
                attributes: {
                    powerAdjustmentCapability: Attribute<null | (...)[], any>;
                };
                commands: {
                    cancelPowerAdjustRequest: Command<void, void, any>;
                    powerAdjustRequest: Command<TypeFromFields<{
                        cause: ...;
                        duration: ...;
                        power: ...;
                    }>, void, any>;
                };
                events: {
                    powerAdjustEnd: Event<TypeFromFields<{
                        cause: ...;
                        duration: ...;
                        energyUse: ...;
                    }>, any>;
                    powerAdjustStart: Event<void, any>;
                };
            };
            flags: {
                powerAdjustment: true;
            };
        }, {
            component: {
                attributes: {
                    forecast: Attribute<null | TypeFromFields<(...)>, any>;
                };
            };
            flags: {
                powerForecastReporting: true;
            };
        }, {
            component: {
                attributes: {
                    forecast: Attribute<null | TypeFromFields<(...)>, any>;
                };
            };
            flags: {
                stateForecastReporting: true;
            };
        }, {
            component: {
                attributes: {
                    optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
                };
            };
            flags: {
                powerAdjustment: true;
            };
        }, {
            component: {
                attributes: {
                    optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
                };
            };
            flags: {
                startTimeAdjustment: true;
            };
        }, {
            component: {
                attributes: {
                    optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
                };
            };
            flags: {
                pausable: true;
            };
        }, {
            component: {
                attributes: {
                    optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
                };
            };
            flags: {
                forecastAdjustment: true;
            };
        }, {
            component: {
                attributes: {
                    optOutState: Attribute<DeviceEnergyManagement.OptOutState, any>;
                };
            };
            flags: {
                constraintBasedAdjustment: true;
            };
        }, {
            component: {
                commands: {
                    pauseRequest: Command<TypeFromFields<{
                        cause: ...;
                        duration: ...;
                    }>, void, any>;
                    resumeRequest: Command<void, void, any>;
                };
                events: {
                    paused: Event<void, any>;
                    resumed: Event<TypeFromFields<{
                        cause: ...;
                    }>, any>;
                };
            };
            flags: {
                pausable: true;
            };
        }, {
            component: {
                commands: {
                    startTimeAdjustRequest: Command<TypeFromFields<{
                        cause: ...;
                        requestedStartTime: ...;
                    }>, void, any>;
                };
            };
            flags: {
                startTimeAdjustment: true;
            };
        }, {
            component: {
                commands: {
                    modifyForecastRequest: Command<TypeFromFields<{
                        cause: ...;
                        forecastId: ...;
                        slotAdjustments: ...;
                    }>, void, any>;
                };
            };
            flags: {
                forecastAdjustment: true;
            };
        }, {
            component: {
                commands: {
                    requestConstraintBasedForecast: Command<TypeFromFields<{
                        cause: ...;
                        constraints: ...;
                    }>, void, any>;
                };
            };
            flags: {
                constraintBasedAdjustment: true;
            };
        }, {
            component: {
                commands: {
                    cancelRequest: Command<void, void, any>;
                };
            };
            flags: {
                startTimeAdjustment: true;
            };
        }, {
            component: {
                commands: {
                    cancelRequest: Command<void, void, any>;
                };
            };
            flags: {
                forecastAdjustment: true;
            };
        }, {
            component: {
                commands: {
                    cancelRequest: Command<void, void, any>;
                };
            };
            flags: {
                constraintBasedAdjustment: true;
            };
        }, {
            component: false;
            flags: {
                feature: false;
                startTimeAdjustment: true;
                stateForecastReporting: false;
            };
        }, {
            component: false;
            flags: {
                feature: false;
                pausable: true;
                stateForecastReporting: false;
            };
        }, {
            component: false;
            flags: {
                feature: false;
                forecastAdjustment: true;
                stateForecastReporting: false;
            };
        }, {
            component: false;
            flags: {
                constraintBasedAdjustment: true;
                feature: false;
                stateForecastReporting: false;
            };
        }, {
            component: false;
            flags: {
                feature: false;
                powerForecastReporting: false;
                startTimeAdjustment: true;
            };
        }, {
            component: false;
            flags: {
                feature: false;
                pausable: true;
                powerForecastReporting: false;
            };
        }, {
            component: false;
            flags: {
                feature: false;
                forecastAdjustment: true;
                powerForecastReporting: false;
            };
        }, {
            component: false;
            flags: {
                constraintBasedAdjustment: true;
                feature: false;
                powerForecastReporting: false;
            };
        }, {
            component: false;
            flags: {
                constraintBasedAdjustment: false;
                forecastAdjustment: false;
                pausable: false;
                powerAdjustment: false;
                powerForecastReporting: false;
                startTimeAdjustment: false;
                stateForecastReporting: false;
            };
        }];
        features: {
            constraintBasedAdjustment: BitFlag;
            forecastAdjustment: BitFlag;
            pausable: BitFlag;
            powerAdjustment: BitFlag;
            powerForecastReporting: BitFlag;
            startTimeAdjustment: BitFlag;
            stateForecastReporting: BitFlag;
        };
        id: 152;
        name: "DeviceEnergyManagement";
        revision: 3;
    }>, Type<Of<{
        attributes: {};
        commands: {};
        events: {};
        id: 0;
        name: "Unknown";
        revision: 0;
    }>, typeof ClusterBehavior, DeviceEnergyManagementInterface>>)
    supervisor: RootSupervisor
    supports: ((other: Type) => boolean)

    Type declaration

      • (other): boolean
      • Does this behavior support functionality of a specific implementation?

        Parameters

        Returns boolean

    Methods

    • Execute logic with elevated privileges.

      The provided function executes with privileges escalated to offline mode. This is not commonly necessary.

      Elevated logic effectively ignores ACLs so should be used with care.

      Note that interactions with the behavior will remain elevated until the synchronous completion of this call. You should only elevate privileges for synchronous logic.

      Parameters

      • fn: (() => void)

        the elevated logic

          • (): void
          • Returns void

      Returns void

    • Create a generic callback function that has the same properties as a Reactor.

      Like a reactor, the callback's "this" will be bound to an active Behavior instance. Because of this: The reactor MUST be a real JS function - arrow functions will not work!

      Type Parameters

      • A extends any[]
      • R

      Parameters

      Returns ((...args: A) => undefined | R)

        • (...args): undefined | R
        • Parameters

          • Rest...args: A

          Returns undefined | R

    • Behaviors are ephemeral and should not perform initialization in their constructor. They can override this method instead.

      This method may be synchronous or asyncronous. If asynchronous, the behavior will not be available for external use until initialization completes.

      Parameters

      • Optional_options: {}

        Returns MaybePromise

      • Install a Reactor.

        Important: The reactor MUST be a real JS function - arrow functions will not work!

        Type Parameters

        Parameters

        Returns void

      • Type Parameters

        Parameters

        Returns This