public T Deserialize <T>(byte[] bytes, ref int currentArrayIndex) where T : class, IMessageSerializable { DeserializeResults <T> results = DeserializeEx <T>(bytes, ref currentArrayIndex, false); return(results.Object); }
public virtual DeserializeResults <T> Deserialize <T>(byte[] bytes, ref int currentArrayIndex, bool suppressExceptions) where T : class, IMessageSerializable { DeserializeResults <T> results = new DeserializeResults <T>(); try { results.Object = (T)Deserialize(bytes, ref currentArrayIndex, results.Status); } catch (Exception ex) { if (suppressExceptions) { results.Status.Exception = ex; } else { throw; } } return(results); }