public override JObject ToJObject(TCAPIVersion version) { var result = base.ToJObject(version); if (id != null) { result.Add("id", id.ToString()); } if (stored != null) { result.Add("stored", stored.Value.ToString(ISODateTimeFormat)); } if (authority != null) { result.Add("authority", authority.ToJObject(version)); } if (version != null) { result.Add("version", version.ToString()); } // CAW 3/32/2021 if (attachments != null && attachments.Count > 0) { var jattachments = new JArray(); result.Add("attachments", jattachments); foreach (var attachment in attachments) { jattachments.Add(attachment.ToJObject(version)); } } return(result); }
public override JObject ToJObject(TCAPIVersion version) { JObject result = base.ToJObject(version); if (id != null) { result.Add("id", id.ToString()); } if (stored != null) { result.Add("stored", stored.Value.ToString(ISODateTimeFormat)); } if (authority != null) { result.Add("authority", authority.ToJObject(version)); } if (version != null) { result.Add("version", version.ToString()); } return result; }
public override JObject ToJObject(TCAPIVersion version) { JObject result = base.ToJObject(version); if (id != null) { result.Add("id", id.ToString()); } if (stored != null) { result.Add("stored", stored.Value.ToString(ISODateTimeFormat)); } if (authority != null) { result.Add("authority", authority.ToJObject(version)); } if (version != null) { result.Add("version", version.ToString()); } return(result); }
/// <summary> /// To the j object. /// </summary> /// <param name="version">The version.</param> /// <returns>JObject.</returns> public override JObject ToJObject(TCAPIVersion version) { var result = base.ToJObject(version); if (ID != null) { result.Add("id", ID.ToString()); } if (Stored != null) { result.Add("stored", Stored.Value.ToString(ISO_DATE_TIME_FORMAT)); } if (Authority != null) { result.Add("authority", Authority.ToJObject(version)); } if (version != null) { result.Add("version", version.ToString()); } return(result); }
public override JObject ToJObject(TCAPIVersion version) { var result = base.ToJObject(version); if (Id != null) { result.Add("id", Id.ToString()); } if (Stored != null) { result.Add("stored", Stored.Value.ToString(IsoDateTimeFormat)); } if (Authority != null) { result.Add("authority", Authority.ToJObject(version)); } if (version != null) { result.Add("version", version.ToString()); } return(result); }