Esempio n. 1
0
        public void TestFastPropertyGet()
        {
            var   a    = new { ID = 1, Name = "张三" };
            TypeX type = a.GetType();

            Assert.AreEqual(1, type.GetProperty("ID").GetValue(a));
            Assert.AreEqual("张三", type.GetProperty("Name").GetValue(a));
        }