コード例 #1
0
        public void TestMethod1()
        {
            var obj = new DTOWXTest()
            {
                Name     = "123",
                CodeEx   = "111111111",
                DataId   = "12312xx",
                DataType = 1,
                Id       = 1,
                NameEx   = "123123",
            };

            //ReflectionUtils.GetProperties(typeof(DTOWXTest), x => {
            //});

            //string props = "Name";
            //var propsX = ReflectionUtils.GetPropertiesAsMap(obj, null);

            SaveDocumentData(obj);
            SaveDocumentDataEx(obj);
        }
コード例 #2
0
        /// <summary>
        /// 保存组件的json数据
        /// </summary>
        /// <param name="document"></param>
        public static void SaveDocumentDataEx(DTOWXTest obj)
        {
            var str = obj.ToJson();

            Debug.WriteLine("Ex{0}", str);
        }