
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

using Luban;


namespace Server.Config
{
public sealed partial class NodeConfig : Luban.BeanBase
{
    public NodeConfig(ByteBuf _buf) 
    {
        Id = _buf.ReadInt();
        NodeId = _buf.ReadByte();
        NodeNum = _buf.ReadByte();
        ServerName = _buf.ReadString();
        MaxVer = _buf.ReadInt();
        MinVer = _buf.ReadInt();
        MaxCVer = _buf.ReadInt();
        MinCVer = _buf.ReadInt();
        WebSocketPort = _buf.ReadInt();
        InnerNetPort = _buf.ReadInt();
        OuterNetPort = _buf.ReadInt();
        InnerHost = _buf.ReadString();
        OnTime = _buf.ReadInt();
    }

    public static NodeConfig DeserializeNodeConfig(ByteBuf _buf)
    {
        return new NodeConfig(_buf);
    }

    /// <summary>
    /// id
    /// </summary>
    public readonly int Id;
    /// <summary>
    /// 模块id
    /// </summary>
    public readonly byte NodeId;
    /// <summary>
    /// 节点编号
    /// </summary>
    public readonly byte NodeNum;
    /// <summary>
    /// 服务器名称
    /// </summary>
    public readonly string ServerName;
    /// <summary>
    /// 大版本
    /// </summary>
    public readonly int MaxVer;
    /// <summary>
    /// 小版本
    /// </summary>
    public readonly int MinVer;
    /// <summary>
    /// 兼容客户端的最大版本
    /// </summary>
    public readonly int MaxCVer;
    /// <summary>
    /// 兼容客户端的最小版本
    /// </summary>
    public readonly int MinCVer;
    /// <summary>
    /// WebSocket端口<br/>0表示不开启
    /// </summary>
    public readonly int WebSocketPort;
    /// <summary>
    /// 内部网络端口
    /// </summary>
    public readonly int InnerNetPort;
    /// <summary>
    /// 外部网络端口<br/>0表示不开启
    /// </summary>
    public readonly int OuterNetPort;
    /// <summary>
    /// 内部网络地址（内网地址）
    /// </summary>
    public readonly string InnerHost;
    /// <summary>
    /// 定时器时间间隔
    /// </summary>
    public readonly int OnTime;
   
    public const int __ID__ = -1552158716;
    public override int GetTypeId() => __ID__;


    public override string ToString()
    {
        return "{ "
        + "id:" + Id + ","
        + "NodeId:" + NodeId + ","
        + "NodeNum:" + NodeNum + ","
        + "ServerName:" + ServerName + ","
        + "MaxVer:" + MaxVer + ","
        + "MinVer:" + MinVer + ","
        + "MaxCVer:" + MaxCVer + ","
        + "MinCVer:" + MinCVer + ","
        + "WebSocketPort:" + WebSocketPort + ","
        + "InnerNetPort:" + InnerNetPort + ","
        + "OuterNetPort:" + OuterNetPort + ","
        + "InnerHost:" + InnerHost + ","
        + "onTime:" + OnTime + ","
        + "}";
    }
}

}
