Пример #1
0
        public static AutoCSer.Net.TcpStaticServer.Client NewTcpClient(AutoCSer.Net.TcpInternalServer.ServerAttribute attribute, Action <SubArray <byte> > onCustomData, ILog log, Func <AutoCSer.Net.TcpInternalServer.ClientSocketSender, bool> verifyMethod)
        {
            KfCall.TcpClient = new AutoCSer.Net.TcpStaticServer.Client(attribute, onCustomData, log, verifyMethod);
            CommandBase tcpClient = KfCall.TcpClient;

            Type[] array = new Type[7];
            array[0] = typeof(KfCall._p12);
            array[1] = typeof(KfCall._p15);
            array[2] = typeof(KfCall._p18);
            array[3] = typeof(KfCall._p27);
            array[4] = typeof(KfCall._p29);
            array[5] = typeof(KfCall._p30);
            Type[] simpleSerializeTypes = array;
            array    = new Type[4];
            array[0] = typeof(KfCall._p6);
            array[1] = typeof(KfCall._p10);
            array[2] = typeof(KfCall._p31);
            Type[] simpleDeSerializeTypes = array;
            array     = new Type[12];
            array[0]  = typeof(KfCall._p1);
            array[1]  = typeof(KfCall._p3);
            array[2]  = typeof(KfCall._p5);
            array[3]  = typeof(KfCall._p7);
            array[4]  = typeof(KfCall._p9);
            array[5]  = typeof(KfCall._p11);
            array[6]  = typeof(KfCall._p19);
            array[7]  = typeof(KfCall._p20);
            array[8]  = typeof(KfCall._p22);
            array[9]  = typeof(KfCall._p23);
            array[10] = typeof(KfCall._p25);
            Type[] serializeTypes = array;
            array     = new Type[12];
            array[0]  = typeof(KfCall._p2);
            array[1]  = typeof(KfCall._p4);
            array[2]  = typeof(KfCall._p8);
            array[3]  = typeof(KfCall._p13);
            array[4]  = typeof(KfCall._p14);
            array[5]  = typeof(KfCall._p16);
            array[6]  = typeof(KfCall._p17);
            array[7]  = typeof(KfCall._p21);
            array[8]  = typeof(KfCall._p24);
            array[9]  = typeof(KfCall._p26);
            array[10] = typeof(KfCall._p28);
            Type[] deSerializeTypes = array;
            array = new Type[1];
            Type[] jsonSerializeTypes = array;
            array = new Type[1];
            tcpClient.ClientCompileSerialize(simpleSerializeTypes, simpleDeSerializeTypes, serializeTypes, deSerializeTypes, jsonSerializeTypes, array);
            return(KfCall.TcpClient);
        }