package gov.va.med.esr;

import javax.jws.WebMethod;
import javax.jws.WebParam;
import javax.jws.WebResult;
import javax.jws.WebService;
import javax.jws.soap.SOAPBinding;

@WebService(serviceName="ComplexService2", name="ComplexPortType2")
@SOAPBinding(style=SOAPBinding.Style.DOCUMENT,use=SOAPBinding.Use.LITERAL,parameterStyle=SOAPBinding.ParameterStyle.WRAPPED)
public class ComplexImpl2
{

@WebMethod()
@WebResult(name="IntegerOutput",targetNamespace="http://example.org/complex2")
          public int echoInt(@WebParam(name="IntegerInput",targetNamespace="http://example.org/complex2")int input)
              {
                    System.out.println("\n\n\techoInt ‘" + input + "‘ to you too!");
                   return input;
               }

@WebMethod(operationName="echoComplexType")
@WebResult(name="EchoStructReturnMessage",targetNamespace="http://example.org/complex2")
           public BasicStruct echoStruct(BasicStruct struct)
                {
                      System.out.println("\n\n\techoComplexType called");
                     return struct;
                 }

@WebMethod(operationName="echoOrderStatus")
@WebResult(name="EchoOrderStatusReturnMessage",targetNamespace="http://example.org/complex2")

                 public OrderStatus putOrder (Order order)
                 {
                     System.out.println("\n\n\techoOrderStatus called order.getOrderName(): "+order.getOrderName());
                     OrderStatus orderStatus=new OrderStatus();
                     orderStatus.setDate(new java.util.Date());
                     orderStatus.setOrder(order);
                     return orderStatus;
      }
}