/// <summary> /// Converts the specified Base64-encoded string value to a byte /// array and returns a <see cref="BinarySerialized{T}"/>. /// </summary> /// <param name="base64Value"></param> /// <returns></returns> public static BinarySerialized <T> FromBase64(string base64Value) { var ret = new BinarySerialized <T> { IsCompressed = false }; ret.ConvertFromBase64(base64Value); return(ret); }
/// <summary> /// Returns a Base64-encoded string version of the <see cref="SerializedValue"/>. /// </summary> /// <param name="obj">The object to be converted to Base64 encoding.</param> /// <returns></returns> public static string ToBase64(T obj) { var ret = new BinarySerialized <T>(obj); return(ret.ToBase64()); }