public static DbActionInfo Deserialize(string base64) { if (string.IsNullOrEmpty(base64)) { throw new ArgumentNullException("base64"); } string json = CompressHelper.GzipDecompress(base64); return(Newtonsoft.Json.JsonConvert.DeserializeObject <DbActionInfo>(json)); }
public static string Serialize(DbActionInfo info) { if (info == null) { throw new ArgumentNullException("info"); } string json = Newtonsoft.Json.JsonConvert.SerializeObject(info); return(CompressHelper.GzipCompress(json)); }