Esempio n. 1
0
        internal static void TestProtoPacketsPerf()
        {
            short psize;
            PUserLogin p = new PUserLogin
            {
                UserName = "******",
                Password = "******"
            };
            p.Setup();
            byte[] ps = p.Serialize();
            BasePacket.Deserialize(ps, ps.Length, 0, out psize);

            HRTimer timer = HRTimer.CreateAndStart();
            Parallel.For(0, ITERATIONS_COUNT, i =>
//            for (int i = 0; i < ITERATIONS_COUNT; i++)
            {
                p.Setup();
                ps = p.Serialize();
                BasePacket.Deserialize(ps, ps.Length, 0, out psize);
            });
//            }
            System.Console.WriteLine(timer.StopWatch());
        }
Esempio n. 2
0
 public RUserLogin(PUserLogin rUserLogin)
     : base(rUserLogin)
 {
 }