// SPDX-License-Identifier: BSD-3-Clause
//
// Copyright 2025 Raritan Inc. All rights reserved.
//
// This file was generated by IdlC from Net.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.net {

  public class WlanInfo : ICloneable {
    public object Clone() {
      WlanInfo copy = new WlanInfo();
      copy.associated = this.associated;
      copy.ssid = this.ssid;
      copy.bssid = this.bssid;
      copy.channel = this.channel;
      copy.channelWidth = this.channelWidth;
      return copy;
    }

    public LightJson.JsonObject Encode() {
      LightJson.JsonObject json = new LightJson.JsonObject();
      json["associated"] = this.associated;
      json["ssid"] = this.ssid;
      json["bssid"] = this.bssid;
      json["channel"] = this.channel;
      json["channelWidth"] = (int)this.channelWidth;
      return json;
    }

    public static WlanInfo Decode(LightJson.JsonObject json, Agent agent) {
      WlanInfo inst = new WlanInfo();
      inst.associated = (bool)json["associated"];
      inst.ssid = (string)json["ssid"];
      inst.bssid = (string)json["bssid"];
      inst.channel = (int)json["channel"];
      inst.channelWidth = (Com.Raritan.Idl.net.WlanChannelWidth)(int)json["channelWidth"];
      return inst;
    }

    public bool associated = false;
    public string ssid = "";
    public string bssid = "";
    public int channel = 0;
    public Com.Raritan.Idl.net.WlanChannelWidth channelWidth = Com.Raritan.Idl.net.WlanChannelWidth.CHANNEL_WIDTH_UNKNOWN;
  }
}
