void ttt() { //Demo.TestStatic(); int ibox = 0; //JObject jbox = ibox; //Demo.FieldSI = 3000; //int fsi = Demo.FieldSI; //int fsi2 = Demo.FieldSI; //Demo.FieldSI = 500; var demoProp = new Demo(); //demoProp.DObject((int)1); //demoProp.DTObj<int?>((int?)555); //demoProp.DTObj<Demo>(demoProp); //demoProp.DTObjAry<int?>(new int?[] { 1, 2, null, 5 }); //demoProp.DTObjAry<Demo>(new Demo[] { demoProp, demoProp, null, demoProp }); //demoProp.DDemo(demoProp); //demoProp.DDemoAry(new Demo[] { demoProp, null }); //demoProp.DObject((int)1); //demoProp.DObject((string)"xx"); //Console.WriteLine(); //demoProp.DObjectAry(new JObject[] { 1, "xx", (int?)2, (int?)null, 2.0, demoProp }); object returnvalue = null; returnvalue = demoProp.DBool(true); returnvalue = demoProp.DBool(false); demoProp.DBool((bool?)true); demoProp.DBool((bool?)false); //demoProp.DBool(null); //demoProp.DBoolArray((bool?[])null); //demoProp.DBoolArray(new bool?[] { true, false, null }); //demoProp.DString("xxx"); //demoProp.DStringAry(new string[]{"xxx", "vvv"}); //demoProp.DStringAry(null); ////demoProp.SayT<int?>(5); ////demoProp.SayT<int?>(new int?[] { }); //int joInt = demoProp.SayT<JObject>(5); //string joStr = demoProp.SayT<JObject>("xxx"); //JObject joDemo = demoProp.SayT<JObject>(new Demo("vvv")); //var jorDemo = joDemo.ToCast<Demo>(); //string[] joAryRs2 = demoProp.SayT<String>(new string[] { "string", "xxx" }); JObject[] joAryRs = demoProp.SayT<JObject>(new JObject[] { new Demo("gg"), new Demo("gg") }); foreach(var o in joAryRs){ var joDemos = o.ToDotValue<Demo>(); } //int agettt = demoProp.Age; //demoProp.Age = 2; //agettt = demoProp.Age; demoProp.SayObject(null); demoProp.SayObject(5); demoProp.SayObject(true); demoProp.SayObject('a'); demoProp.SayObject(1.0F); demoProp.SayObject(1.1D); demoProp.SayObject("vvb"); demoProp.SayObject(new Demo("vvv")); ////new Demo(true); ////new Demo((bool?)null); ////new Demo(new bool[] { true, false }); ////new Demo(new bool?[] { true, false, null }); //JObject dm0 = new Demo(); //new Demo(dm0); //var dm1 = new Demo(); //dm1.SayObject(new JObject[] { dm0, dm1 }); //var dm2 = new Demo(); //new Demo(dm1); //new Demo(new Demo[] { dm1,dm2 }); //var demo = new Demo(new string[]{"cc","tt"}); //Demo.DemoReturn<Demo>(demo); //Demo.DemoReturnArray<Demo>(demo,demo); ////Demo.DemoArray(demo); ////Demo.DemoT<Demo>(demo, demo); //Demo.DemoTArray<Demo>(demo, demo); //Console.WriteLine(""); //Console.WriteLine(">>> 按下任意键结束。"); //Console.ReadKey(true); //JAssembly.Dispose(); //if (1 == 1) return; //Array ary = (Array)(new int[] { 2, 3, 4 }); //Type tt = ary.GetType(); //if (tt.IsArray) //{ // Type ttt = tt.GetElementType(); //} }