// SPDX-License-Identifier: BSD-3-Clause
//
// Copyright 2026 Raritan Inc. All rights reserved.
//
// This file was generated by IdlC from Webcam.idl.

using System;
using System.Linq;
using LightJson;
using Com.Raritan.Idl;
using Com.Raritan.JsonRpc;
using Com.Raritan.Util;

#pragma warning disable 0108, 0219, 0414, 1591

namespace Com.Raritan.Idl.webcam {

  public class Settings_2_0_0 : ICloneable {
    public object Clone() {
      Settings_2_0_0 copy = new Settings_2_0_0();
      copy.format = this.format;
      copy.controls = this.controls;
      copy.name = this.name;
      copy.location = this.location;
      copy.refreshInterval = this.refreshInterval;
      return copy;
    }

    public LightJson.JsonObject Encode() {
      LightJson.JsonObject json = new LightJson.JsonObject();
      json["format"] = this.format.Encode();
      json["controls"] = this.controls.Encode();
      json["name"] = this.name;
      json["location"] = this.location.Encode();
      json["refreshInterval"] = this.refreshInterval;
      return json;
    }

    public static Settings_2_0_0 Decode(LightJson.JsonObject json, Agent agent) {
      Settings_2_0_0 inst = new Settings_2_0_0();
      inst.format = Com.Raritan.Idl.webcam.Format_2_0_0.Decode(json["format"], agent);
      inst.controls = Com.Raritan.Idl.webcam.Controls.Decode(json["controls"], agent);
      inst.name = (string)json["name"];
      inst.location = Com.Raritan.Idl.webcam.Location.Decode(json["location"], agent);
      inst.refreshInterval = (int)json["refreshInterval"];
      return inst;
    }

    public Com.Raritan.Idl.webcam.Format_2_0_0 format = new Com.Raritan.Idl.webcam.Format_2_0_0();
    public Com.Raritan.Idl.webcam.Controls controls = new Com.Raritan.Idl.webcam.Controls();
    public string name = "";
    public Com.Raritan.Idl.webcam.Location location = new Com.Raritan.Idl.webcam.Location();
    public int refreshInterval = 0;
  }
}
