示例#1
0
 /// <summary>
 /// Reads the JSON or XML document and returns the deserialized object.
 /// </summary>
 /// <param name="serializedObject">The serialized object.</param>
 /// <param name="format">The format of the serialized object.</param>
 /// <returns>The deserialized object.</returns>
 public static T FromString(string serializedObject, MessageFormat format)
 {
     return Serialization.Deserialise<T>(serializedObject, format);
 }
示例#2
0
 /// <summary>
 /// Reads the JSON or XML document and returns the deserialized object.
 /// </summary>
 /// <param name="serializedObject">The serialized object.</param>
 /// <param name="format">The format of the serialized object.</param>
 /// <returns>The deserialized object.</returns>
 public static Proof FromString(string serializedObject, MessageFormat format)
 {
     return(Serialization.Deserialise <Proof>(serializedObject, format));
 }
示例#3
0
 /// <summary>
 /// Reads the JSON or XML document and returns the deserialized object.
 /// </summary>
 /// <param name="serializedObject">The serialized object.</param>
 /// <param name="format">The format of the serialized object.</param>
 /// <returns>The deserialized object.</returns>
 public static TC FromString(string serializedObject, MessageFormat format = MessageFormat.Json)
 {
     return(Serialization.Deserialise <TC>(serializedObject, format));
 }
 /// <summary>
 /// Reads the JSON or XML document and returns the deserialized object.
 /// </summary>
 /// <param name="serializedObject">The serialized object.</param>
 /// <param name="format">The format of the serialized object.</param>
 /// <returns>The deserialized object.</returns>
 public static DeviceRegistration FromString(string serializedObject, MessageFormat format)
 {
     return(Serialization.Deserialise <DeviceRegistration>(serializedObject, format));
 }