MELCloud & MELCloud Home API for Node.js - v48.2.0
    Preparing search index...

    Function classicUpdateDevices

    • Method decorator factory that propagates data changes to device models after the decorated method completes. Supports filtering by device type; the patch-computation strategy is explicit via the kind option ('payload' or 'power') rather than inferred from the method name.

      Parameters

      • root0: { kind?: UpdatePatchKind; type?: ClassicDeviceType } = {}

        Options object.

        • Optionalkind?: UpdatePatchKind

          Patch-computation strategy (default 'payload').

        • Optionaltype?: ClassicDeviceType

          Optional device type to filter which devices are updated. When omitted, every device in the facade is patched.

      Returns <TArgs extends readonly unknown[]>(
          target: (...args: TArgs) => Promise<void>,
          _context: ClassMethodDecoratorContext,
      ) => (...args: TArgs) => Promise<void>

      A method decorator that updates device models after execution.

      NoChangesError from the wrapped method when it is called with an empty-object payload carrying no fields to apply.