/**
 * @license
 * Copyright 2022-2026 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
import { EndpointInitializer } from "#endpoint/properties/EndpointInitializer.js";
import { NodePhysicalProperties } from "#node/NodePhysicalProperties.js";
const cache = /* @__PURE__ */ new WeakMap();
function ClientNodePhysicalProperties(node) {
  const existing = cache.get(node);
  if (existing) {
    return existing;
  }
  let properties;
  const result = {
    get supportsThread() {
      return props().supportsThread;
    },
    get supportsWifi() {
      return props().supportsWifi;
    },
    get supportsEthernet() {
      return props().supportsEthernet;
    },
    get rootEndpointServerList() {
      return props().rootEndpointServerList;
    },
    get isMainsPowered() {
      return props().isMainsPowered;
    },
    get isBatteryPowered() {
      return props().isBatteryPowered;
    },
    get isIntermittentlyConnected() {
      return props().isIntermittentlyConnected;
    },
    get isThreadSleepyEndDevice() {
      return props().isThreadSleepyEndDevice;
    }
  };
  cache.set(node, result);
  const structure = node.env.get(EndpointInitializer).structure;
  structure.changed.on(() => properties = void 0);
  return result;
  function props() {
    if (properties === void 0) {
      properties = NodePhysicalProperties(node);
    }
    return properties;
  }
}
export {
  ClientNodePhysicalProperties
};
//# sourceMappingURL=ClientNodePhysicalProperties.js.map
