public override void PrimeOutput(int outputs, int[] outputIDs, PipelineBuffer[] buffers) { var binding = new BasicHttpBinding(); binding.MaxReceivedMessageSize = 999999999; var proxy = new CAdxWebServiceXmlCCClient(binding, new EndpointAddress("http://" + Ip + ":28880/adxwsvc/services/CAdxWebServiceXmlCC")); var parameters = new List <CAdxParamKeyValue>(); var response = proxy.query(CallContext, PublicIdentifier, parameters.ToArray(), 2); var xml = new XmlDocument(); xml.LoadXml(response.resultXml); var responseXmlWrapper = new X3ListResponseWrapper(xml); foreach (var line in responseXmlWrapper.Lines) { buffers[0].AddRow(); foreach (var field in line.Fields) { var index = GetCollumnIndex(field.Name); buffers[0].SetString(index, field.Value); } } buffers[0].SetEndOfRowset(); }
public override void PrimeOutput(int outputs, int[] outputIDs, PipelineBuffer[] buffers) { var outputBuffer = buffers[0]; var parameters = new List <CAdxParamKeyValue>(); var response = WebService.query(X3WebService.Context, PublicIdentifierValue, parameters.ToArray(), 10); var xml = new XmlDocument(); xml.LoadXml(response.resultXml); var responseXmlWrapper = new X3ListResponseWrapper(xml); foreach (var lineTag in responseXmlWrapper.Lines) { outputBuffer.AddRow(); foreach (var fieldTag in lineTag.Fields) { var outputCollumnIndex = GetOutputColumnIndex(fieldTag.Name); var outputColumn = GetOutputColumn(fieldTag.Name); SetColumnData(outputBuffer, outputCollumnIndex, fieldTag.Value, outputColumn.DataType); } } outputBuffer.SetEndOfRowset(); }