public static object Parse(Type type, string json) { object result = TJson.Deserialize(type, json); IJson jObj = result as IJson; if (jObj != null) { jObj.AfterDeserialize(); } return(result); }
public string ToJson() { BeforeSerialize(); return(TJson.ToJson(this, this.GetType())); }
protected virtual void AfterDeserialize(TJson obj) { }
protected virtual void BeforeSerialize(TJson obj) { }
public string ToJson() { BeforeSerialize(); return(TJson.ToJson(this, GetJasonDataType())); }
public static T DeepClone <T>(this TJson Source) where T : TJson { string jsonString = Source.ToJson(); return(jsonString.ParseJSON <T>()); }
public T Create <T>() where T : SerializableData { return(TJson.DeepColne <T>(this as T)); }