public static T Deserialize <T>(byte[] data, bool suppressErrors = true) { try { var s = new Gro.Serializer(new Gro.DataMembersExtracters.PropertiesExtractor(), options: Gro.GroBufOptions.None); return(s.Deserialize <T>(data)); } catch (Exception e) { if (!suppressErrors) { ExceptionDispatchInfo.Capture(e).Throw(); } return(default);
public static byte[] Serialize(Type type, object objectToSerialize, bool compress = true) { var s = new Gro.Serializer(new Gro.DataMembersExtracters.PropertiesExtractor(), options: Gro.GroBufOptions.None); return(s.Serialize(objectToSerialize)); }
public static byte[] Serialize <T>(T objectToSerialize) { var s = new Gro.Serializer(new Gro.DataMembersExtracters.PropertiesExtractor(), options: Gro.GroBufOptions.None); return(s.Serialize(objectToSerialize)); }