"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
  for (var name in all)
    __defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
  if (from && typeof from === "object" || typeof from === "function") {
    for (let key of __getOwnPropNames(from))
      if (!__hasOwnProp.call(to, key) && key !== except)
        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
  }
  return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var DeviceEnergyManagementMode_exports = {};
__export(DeviceEnergyManagementMode_exports, {
  DeviceEnergyManagementMode: () => DeviceEnergyManagementMode
});
module.exports = __toCommonJS(DeviceEnergyManagementMode_exports);
var import_MatterDefinition = require("../MatterDefinition.js");
var import_elements = require("../../elements/index.js");
/**
 * @license
 * Copyright 2022-2025 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
const DeviceEnergyManagementMode = (0, import_elements.ClusterElement)(
  {
    name: "DeviceEnergyManagementMode",
    id: 159,
    type: "ModeBase",
    classification: "application",
    pics: "DEMM",
    details: "This cluster is derived from the Mode Base cluster, defining additional mode tags and namespaced enumerated values for Device Energy Management devices.\nNOTE Support for Device Energy Management Mode cluster is provisional.",
    xref: { document: "cluster", section: "9.6" }
  },
  (0, import_elements.AttributeElement)({ name: "ClusterRevision", id: 65533, type: "ClusterRevision", default: 1 }),
  (0, import_elements.DatatypeElement)({
    name: "ModeOptionStruct",
    type: "ModeOptionStruct",
    details: "The table below lists the changes relative to the Mode Base cluster for the fields of the ModeOptionStruct type. A blank field indicates no change.",
    xref: { document: "cluster", section: "9.6.4.1" }
  }),
  (0, import_elements.DatatypeElement)(
    { name: "ModeTag", type: "enum16" },
    (0, import_elements.FieldElement)({
      name: "NoOptimization",
      id: 16384,
      details: "The device prohibits optimization of energy usage management: its energy usage is determined only by the user configuration and internal device needs. This tag cannot be included with any of the other tags defined below in a mode.",
      xref: { document: "cluster", section: "9.6.5.1.1" }
    }),
    (0, import_elements.FieldElement)({
      name: "DeviceOptimization",
      id: 16385,
      details: "The device is permitted to manage its own energy usage. For example, using tariff information it may obtain.",
      xref: { document: "cluster", section: "9.6.5.1.2" }
    }),
    (0, import_elements.FieldElement)({
      name: "LocalOptimization",
      id: 16386,
      details: "The device permits management of energy usage by an energy manager to optimize the local energy usage.",
      xref: { document: "cluster", section: "9.6.5.1.3" }
    }),
    (0, import_elements.FieldElement)({
      name: "GridOptimization",
      id: 16387,
      details: "The device permits management of energy usage by an energy manager to optimize the grid energy usage.",
      xref: { document: "cluster", section: "9.6.5.1.4" }
    })
  )
);
import_MatterDefinition.MatterDefinition.children.push(DeviceEnergyManagementMode);
//# sourceMappingURL=DeviceEnergyManagementMode.js.map
