Exemple #1
0
            public void endServiceDelivery_Process(int seqid, TProtocol iprot, TProtocol oprot)
            {
                endServiceDelivery_args args = new endServiceDelivery_args();

                args.Read(iprot);
                iprot.ReadMessageEnd();
                endServiceDelivery_result result = new endServiceDelivery_result();

                try {
                    iface_.endServiceDelivery(args.ServiceID.Value, args.ServiceDeliveryToken, args.UnitsReceived.Value);
                } catch (Worldpay.Innovation.WPWithin.Rpc.Types.Error err) {
                    result.Err = err;
                }
                oprot.WriteMessageBegin(new TMessage("endServiceDelivery", TMessageType.Reply, seqid));
                result.Write(oprot);
                oprot.WriteMessageEnd();
                oprot.Transport.Flush();
            }
Exemple #2
0
            public void endServiceDelivery_Process(int seqid, TProtocol iprot, TProtocol oprot)
            {
                endServiceDelivery_args args = new endServiceDelivery_args();

                args.Read(iprot);
                iprot.ReadMessageEnd();
                endServiceDelivery_result result = new endServiceDelivery_result();

                try
                {
                    try
                    {
                        iface_.endServiceDelivery(args.ServiceID.Value, args.ServiceDeliveryToken, args.UnitsReceived.Value);
                    }
                    catch (Worldpay.Innovation.WPWithin.Rpc.Types.Error err)
                    {
                        result.Err = err;
                    }
                    oprot.WriteMessageBegin(new TMessage("endServiceDelivery", TMessageType.Reply, seqid));
                    result.Write(oprot);
                }
                catch (TTransportException)
                {
                    throw;
                }
                catch (Exception ex)
                {
                    Console.Error.WriteLine("Error occurred in processor:");
                    Console.Error.WriteLine(ex.ToString());
                    TApplicationException x = new TApplicationException(TApplicationException.ExceptionType.InternalError, " Internal error.");
                    oprot.WriteMessageBegin(new TMessage("endServiceDelivery", TMessageType.Exception, seqid));
                    x.Write(oprot);
                }
                oprot.WriteMessageEnd();
                oprot.Transport.Flush();
            }