public XElement Serialize() { var result = new XElement(Constants.XMLNamespaces.EHEALTHBOX_PUBLICATION + "SendMessageRequest", new XAttribute("xmlns", Constants.XMLNamespaces.EHEALTHBOX_PUBLICATION)); if (BoxId != null) { result.Add(BoxId.Serialize()); } foreach (var contextType in DestinationContextLst) { result.Add(contextType.Serialize()); } result.Add(ContentContext.Serialize()); foreach (var copyMailTo in CopyMailToLst) { result.Add(new XElement("CopyMailTo", copyMailTo)); } if (!string.IsNullOrWhiteSpace(PublicationId)) { result.Add(new XAttribute("PublicationId", PublicationId)); } return(result); }
public XElement Serialize() { var result = new XElement(Constants.XMLNamespaces.EHEALTHBOX_CONSULTATION + "GetMessagesListRequest", new XAttribute("xmlns", Constants.XMLNamespaces.EHEALTHBOX_CONSULTATION)); if (BoxId != null) { result.Add(BoxId.Serialize()); } result.Add(new XElement("Source", Enum.GetName(typeof(EHealthBoxSources), Source))); result.Add(new XElement("StartIndex", StartIndex)); result.Add(new XElement("EndIndex", EndIndex)); return(result); }
public XElement Serialize() { var result = new XElement(Constants.XMLNamespaces.EHEALTHBOX_CONSULTATION + "DeleteMessageRequest", new XAttribute("xmlns", Constants.XMLNamespaces.EHEALTHBOX_CONSULTATION)); if (BoxId != null) { result.Add(BoxId.Serialize()); } result.Add(new XElement("Source", Enum.GetName(typeof(EHealthBoxSources), Source))); foreach (var messageId in MessageIdLst) { result.Add(new XElement("MessageId", messageId)); } return(result); }