Ejemplo n.º 1
0
        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));
        }
Ejemplo n.º 2
0
        public static string Serialize(DbActionInfo info)
        {
            if (info == null)
            {
                throw new ArgumentNullException("info");
            }

            string json = Newtonsoft.Json.JsonConvert.SerializeObject(info);

            return(CompressHelper.GzipCompress(json));
        }