public void SendMail(MailInfo mailInfo) { var helper = new WebAPIHelper(); var result = helper.Post <Stream>("SendMail", mailInfo); if (result != null) { result.Dispose(); } }
public string ProcessApi(string action, string controller, object request) { if (string.IsNullOrEmpty(action)) { throw new ArgumentNullException("action"); } if (string.IsNullOrEmpty(controller)) { throw new ArgumentNullException("controller"); } var helper = new WebAPIHelper(_url); switch (action.ToUpper()) { case "POST": using (var ms = helper.Post <Stream>(controller, request)) { if (ms != null) { using (var reader = XmlReader.Create(ms)) { var responseXmlDoc = XmlDocumentConverter.ConvertTo <XmlDocument>(reader); if (responseXmlDoc != null) { return(responseXmlDoc.InnerXml); } } } } break; default: throw new NotImplementedException(string.Format("Action '{0}' is not Implemented", action)); } return(null); }
public Stream GetReportPreview(Output task) { var helper = new WebAPIHelper(); return(helper.Post <Stream>("EPSPreviewReport", task)); }
public OutputBatch PrintReportBatch(OutputBatch batch) { var helper = new WebAPIHelper(); return(helper.Post <OutputBatch>("EPSPrintReportBatch", batch)); }
public Output PrintReport(Output task) { var helper = new WebAPIHelper(); return(helper.Post <Output>("EPSPrintReport", task)); }