Example #1
0
        private static DeltaExtras ParseDeltaExtras(JToken data)
        {
            DeltaExtras delta = null;

            if (data != null && data is JObject dataObject)
            {
                var deltaProp = dataObject[DeltaProperty];
                if (deltaProp != null && deltaProp is JObject deltaObject)
                {
                    delta = deltaObject.ToObject <DeltaExtras>();
                }
            }

            return(delta);
        }
Example #2
0
 private MessageExtras(JToken data, DeltaExtras delta)
 {
     Data  = data;
     Delta = delta;
 }
Example #3
0
 /// <summary>
 /// Messages extras is a flexible object that may other properties that are not exposed by the strongly typed implementation.
 /// </summary>
 /// <param name="data">the json object passed to Message extras.</param>
 public MessageExtras(JToken data = null)
 {
     Data  = data;
     Delta = ParseDeltaExtras(data);
 }