"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 service_area_element_exports = {};
__export(service_area_element_exports, {
  ServiceArea: () => ServiceArea
});
module.exports = __toCommonJS(service_area_element_exports);
var import_MatterDefinition = require("../MatterDefinition.js");
var import_elements = require("../../elements/index.js");
/**
 * @license
 * Copyright 2022-2026 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
const ServiceArea = (0, import_elements.ClusterElement)(
  { name: "ServiceArea", id: 336, classification: "application" },
  (0, import_elements.AttributeElement)({ name: "ClusterRevision", id: 65533, type: "ClusterRevision", default: 2 }),
  (0, import_elements.AttributeElement)(
    { name: "FeatureMap", id: 65532, type: "FeatureMap" },
    (0, import_elements.FieldElement)({ name: "SELRUN", constraint: "0", title: "SelectWhileRunning" }),
    (0, import_elements.FieldElement)({ name: "PROG", constraint: "1", title: "ProgressReporting" }),
    (0, import_elements.FieldElement)({ name: "MAPS", constraint: "2", title: "Maps" })
  ),
  (0, import_elements.AttributeElement)(
    { name: "SupportedAreas", id: 0, type: "list", access: "R V", conformance: "M", constraint: "max 255" },
    (0, import_elements.FieldElement)({ name: "entry", type: "AreaStruct" })
  ),
  (0, import_elements.AttributeElement)(
    { name: "SupportedMaps", id: 1, type: "list", access: "R V", conformance: "MAPS", constraint: "max 255" },
    (0, import_elements.FieldElement)({ name: "entry", type: "MapStruct" })
  ),
  (0, import_elements.AttributeElement)(
    {
      name: "SelectedAreas",
      id: 2,
      type: "list",
      access: "R V",
      conformance: "M",
      constraint: "desc",
      default: []
    },
    (0, import_elements.FieldElement)({ name: "entry", type: "uint32" })
  ),
  (0, import_elements.AttributeElement)({
    name: "CurrentArea",
    id: 3,
    type: "uint32",
    access: "R V",
    conformance: "desc",
    constraint: "desc",
    default: null,
    quality: "X"
  }),
  (0, import_elements.AttributeElement)({
    name: "EstimatedEndTime",
    id: 4,
    type: "epoch-s",
    access: "R V",
    conformance: "[CurrentArea]",
    default: null,
    quality: "X Q"
  }),
  (0, import_elements.AttributeElement)(
    {
      name: "Progress",
      id: 5,
      type: "list",
      access: "R V",
      conformance: "PROG",
      constraint: "max 255",
      default: []
    },
    (0, import_elements.FieldElement)({ name: "entry", type: "ProgressStruct" })
  ),
  (0, import_elements.CommandElement)(
    {
      name: "SelectAreas",
      id: 0,
      access: "O",
      conformance: "M",
      direction: "request",
      response: "SelectAreasResponse"
    },
    (0, import_elements.FieldElement)(
      { name: "NewAreas", id: 0, type: "list", conformance: "M", constraint: "desc" },
      (0, import_elements.FieldElement)({ name: "entry", type: "uint32" })
    )
  ),
  (0, import_elements.CommandElement)(
    { name: "SelectAreasResponse", id: 1, access: "O", conformance: "M", direction: "response" },
    (0, import_elements.FieldElement)({ name: "Status", id: 0, type: "SelectAreasStatus", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "StatusText", id: 1, type: "string", conformance: "M", constraint: "max 256" })
  ),
  (0, import_elements.CommandElement)(
    {
      name: "SkipArea",
      id: 2,
      access: "O",
      conformance: "[CurrentArea | Progress]",
      direction: "request",
      response: "SkipAreaResponse"
    },
    (0, import_elements.FieldElement)({ name: "SkippedArea", id: 0, type: "uint32", conformance: "M", constraint: "desc" })
  ),
  (0, import_elements.CommandElement)(
    { name: "SkipAreaResponse", id: 3, access: "O", conformance: "SkipArea", direction: "response" },
    (0, import_elements.FieldElement)({ name: "Status", id: 0, type: "SkipAreaStatus", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "StatusText", id: 1, type: "string", conformance: "M", constraint: "max 256" })
  ),
  (0, import_elements.DatatypeElement)(
    { name: "LandmarkInfoStruct", type: "struct" },
    (0, import_elements.FieldElement)({ name: "LandmarkTag", id: 0, type: "tag", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "RelativePositionTag", id: 1, type: "tag", conformance: "M", quality: "X" })
  ),
  (0, import_elements.DatatypeElement)(
    { name: "AreaInfoStruct", type: "struct" },
    (0, import_elements.FieldElement)({ name: "LocationInfo", id: 0, type: "locationdesc", conformance: "M", quality: "X" }),
    (0, import_elements.FieldElement)({ name: "LandmarkInfo", id: 1, type: "LandmarkInfoStruct", conformance: "M", quality: "X" })
  ),
  (0, import_elements.DatatypeElement)(
    { name: "MapStruct", type: "struct" },
    (0, import_elements.FieldElement)({ name: "MapId", id: 0, type: "uint32", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "Name", id: 1, type: "string", conformance: "M", constraint: "max 64" })
  ),
  (0, import_elements.DatatypeElement)(
    { name: "AreaStruct", type: "struct" },
    (0, import_elements.FieldElement)({ name: "AreaId", id: 0, type: "uint32", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "MapId", id: 1, type: "uint32", conformance: "M", constraint: "desc", quality: "X" }),
    (0, import_elements.FieldElement)({ name: "AreaInfo", id: 2, type: "AreaInfoStruct", conformance: "M" })
  ),
  (0, import_elements.DatatypeElement)(
    { name: "ProgressStruct", type: "struct" },
    (0, import_elements.FieldElement)({ name: "AreaId", id: 0, type: "uint32", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "Status", id: 1, type: "OperationalStatusEnum", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "TotalOperationalTime", id: 2, type: "elapsed-s", conformance: "O", quality: "X" }),
    (0, import_elements.FieldElement)({ name: "EstimatedTime", id: 3, type: "elapsed-s", conformance: "O", quality: "X" })
  ),
  (0, import_elements.DatatypeElement)(
    { name: "OperationalStatusEnum", type: "enum8" },
    (0, import_elements.FieldElement)({ name: "Pending", id: 0, conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "Operating", id: 1, conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "Skipped", id: 2, conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "Completed", id: 3, conformance: "M" })
  ),
  (0, import_elements.DatatypeElement)(
    { name: "SelectAreasStatus", type: "enum8" },
    (0, import_elements.FieldElement)({ name: "Success", id: 0, conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "UnsupportedArea", id: 1, conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "InvalidInMode", id: 2, conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "InvalidSet", id: 3, conformance: "M" })
  ),
  (0, import_elements.DatatypeElement)(
    { name: "SkipAreaStatus", type: "enum8" },
    (0, import_elements.FieldElement)({ name: "Success", id: 0, conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "InvalidAreaList", id: 1, conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "InvalidInMode", id: 2, conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "InvalidSkippedArea", id: 3, conformance: "M" })
  )
);
import_MatterDefinition.MatterDefinition.children.push(ServiceArea);
//# sourceMappingURL=service-area.element.js.map
