Exemple #1
0
        /// <summary>
        /// FromJson
        /// </summary>
        /// <param name="sessionDevices"></param>
        /// <param name="json"></param>
        public static void FromJson(this EltraDeviceSet sessionDevices, string json)
        {
            if (sessionDevices == null)
            {
                throw new ArgumentNullException(nameof(sessionDevices));
            }

            sessionDevices = TryDeserializeObject <EltraDeviceSet>(json);
        }
Exemple #2
0
 /// <summary>
 /// ToJson
 /// </summary>
 /// <param name="sessionDevices"></param>
 /// <returns></returns>
 public static string ToJson(this EltraDeviceSet sessionDevices)
 {
     return(JsonSerializer.Serialize(sessionDevices));
 }