static int IsReConnect(IntPtr L)
    {
        try
        {
            int count = LuaDLL.lua_gettop(L);

            if (count == 2)
            {
                GameFramework.NetManager obj = (GameFramework.NetManager)ToLua.CheckObject <GameFramework.NetManager>(L, 1);
                int  arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
                bool o    = obj.IsReConnect(arg0);
                LuaDLL.lua_pushboolean(L, o);
                return(1);
            }
            else if (count == 3)
            {
                GameFramework.NetManager obj = (GameFramework.NetManager)ToLua.CheckObject <GameFramework.NetManager>(L, 1);
                int  arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
                bool arg1 = LuaDLL.luaL_checkboolean(L, 3);
                bool o    = obj.IsReConnect(arg0, arg1);
                LuaDLL.lua_pushboolean(L, o);
                return(1);
            }
            else
            {
                return(LuaDLL.luaL_throw(L, "invalid arguments to method: GameFramework.NetManager.IsReConnect"));
            }
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }
 static int set_mInst(IntPtr L)
 {
     try
     {
         GameFramework.NetManager arg0 = (GameFramework.NetManager)ToLua.CheckObject <GameFramework.NetManager>(L, 2);
         GameFramework.NetManager.mInst = arg0;
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
 static int OnCloseAndClearAllTcp(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         GameFramework.NetManager obj = (GameFramework.NetManager)ToLua.CheckObject <GameFramework.NetManager>(L, 1);
         obj.OnCloseAndClearAllTcp();
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
 static int Update(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         GameFramework.NetManager obj = (GameFramework.NetManager)ToLua.CheckObject <GameFramework.NetManager>(L, 1);
         obj.Update();
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
 static int ReConnect(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 3);
         GameFramework.NetManager obj = (GameFramework.NetManager)ToLua.CheckObject <GameFramework.NetManager>(L, 1);
         int  arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
         bool arg1 = LuaDLL.luaL_checkboolean(L, 3);
         obj.ReConnect(arg0, arg1);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
 static int RemoveListener(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 4);
         GameFramework.NetManager obj = (GameFramework.NetManager)ToLua.CheckObject <GameFramework.NetManager>(L, 1);
         int         arg0             = (int)LuaDLL.luaL_checknumber(L, 2);
         uint        arg1             = (uint)LuaDLL.luaL_checknumber(L, 3);
         LuaFunction arg2             = ToLua.CheckLuaFunction(L, 4);
         obj.RemoveListener(arg0, arg1, arg2);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
 static int SendData(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 5);
         GameFramework.NetManager obj = (GameFramework.NetManager)ToLua.CheckObject <GameFramework.NetManager>(L, 1);
         int    arg0 = (int)LuaDLL.luaL_checknumber(L, 2);
         byte[] arg1 = ToLua.CheckByteBuffer(L, 3);
         uint   arg2 = (uint)LuaDLL.luaL_checknumber(L, 4);
         object arg3 = ToLua.ToVarObject(L, 5);
         obj.SendData(arg0, arg1, arg2, arg3);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
 static int ConnectAsync(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 8);
         GameFramework.NetManager obj = (GameFramework.NetManager)ToLua.CheckObject <GameFramework.NetManager>(L, 1);
         int         arg0             = (int)LuaDLL.luaL_checknumber(L, 2);
         string      arg1             = ToLua.CheckString(L, 3);
         int         arg2             = (int)LuaDLL.luaL_checknumber(L, 4);
         LuaFunction arg3             = ToLua.CheckLuaFunction(L, 5);
         LuaFunction arg4             = ToLua.CheckLuaFunction(L, 6);
         LuaFunction arg5             = ToLua.CheckLuaFunction(L, 7);
         LuaFunction arg6             = ToLua.CheckLuaFunction(L, 8);
         obj.ConnectAsync(arg0, arg1, arg2, arg3, arg4, arg5, arg6);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
 public ClientSession(IConnection c, NetManager mgr) : base(c, mgr)
 {
     type = 1;
 }