@Test public void outParams() throws Exception { final Service calculatorService = Service.create( new URL("http: new QName("http: assertNotNull(calculatorService); final CalculatorWs calculator = calculatorService.getPort(CalculatorWs.class); final Holder<Integer> sum = new Holder<Integer>(); final Holder<Integer> multiply = new Holder<Integer>(); calculator.sumAndMultiply(4, 6, sum, multiply); assertEquals(10, (int) sum.value); assertEquals(24, (int) multiply.value); }
public void sumAndMultiply(int a, int b, @WebParam(name = "sum", mode = WebParam.Mode.OUT) Holder<Integer> sum, @WebParam(name = "multiply", mode = WebParam.Mode.OUT) Holder<Integer> multiply) { sum.value = a + b; multiply.value = a * b; }
Calculator implements CalculatorWs { public void sumAndMultiply(int a, int b, @WebParam(name = "sum", mode = WebParam.Mode.OUT) Holder<Integer> sum, @WebParam(name = "multiply", mode = WebParam.Mode.OUT) Holder<Integer> multiply) { sum.value = a + b; multiply.value = a * b; } }
Calculator implements CalculatorWs { public void sumAndMultiply(int a, int b, @WebParam(name = "sum", mode = WebParam.Mode.OUT) Holder<Integer> sum, @WebParam(name = "multiply", mode = WebParam.Mode.OUT) Holder<Integer> multiply) { sum.value = a + b; multiply.value = a * b; }  }
Calculator implements CalculatorWs { public void sumAndMultiply(int a, int b, @WebParam(name = "sum", mode = WebParam.Mode.OUT) Holder<Integer> sum, @WebParam(name = "multiply", mode = WebParam.Mode.OUT) Holder<Integer> multiply) { sum.value = a + b; multiply.value = a * b; }  void sumAndMultiply(int a, int b,
                               @WebParam(name = "sum", mode = WebParam.Mode.OUT) Holder<Integer> sum,
                               @WebParam(name = "multiply", mode = WebParam.Mode.OUT) Holder<Integer> multiply); }
Calculator implements CalculatorWs { public void sumAndMultiply(int a, int b, @WebParam(name = "sum", mode = WebParam.Mode.OUT) Holder<Integer> sum, @WebParam(name = "multiply", mode = WebParam.Mode.OUT) Holder<Integer> multiply) { sum.value = a + b; multiply.value = a * b; }  void sumAndMultiply(int a, int b,
                               @WebParam(name = "sum", mode = WebParam.Mode.OUT) Holder<Integer> sum,
                               @WebParam(name = "multiply", mode = WebParam.Mode.OUT) Holder<Integer> multiply);  }