コード例 #1
0
ファイル: JsonConvert.cs プロジェクト: Orden4/WCSharp
 /// <summary>
 /// Converts the given generic class into a JSON string.
 /// <para>Please read the documentation for details on what can and cannot be (de)serialized.</para>
 /// </summary>
 public static string Serialize <T>(T input)
 {
     return(Rxi.Encode(parser, Serialization.SerializeClass(input, typeof(T))));
 }
コード例 #2
0
ファイル: JsonConvert.cs プロジェクト: Orden4/WCSharp
 /// <summary>
 /// Converts the given JSON string into the specified generic class.
 /// <para>Please read the documentation for details on what can and cannot be (de)serialized.</para>
 /// </summary>
 public static object Deserialize(string input, Type deserializeType)
 {
     return(Deserialization.DeserializeLuaTable(new LuaTable(Rxi.Decode(parser, input)), deserializeType));
 }