use of org.apache.header_test.types.TestHeader1Response in project cxf by apache.
the class TestHeaderImpl method testHeader1.
public TestHeader1Response testHeader1(TestHeader1 in, TestHeader1 inHeader) {
if (in == null || inHeader == null) {
throw new IllegalArgumentException("TestHeader1 part not found.");
}
TestHeader1Response returnVal = new TestHeader1Response();
returnVal.setResponseType(inHeader.getClass().getSimpleName());
return returnVal;
}
use of org.apache.header_test.types.TestHeader1Response in project cxf by apache.
the class HeaderClientServerTest method testInHeader.
@Test
public void testInHeader() throws Exception {
URL wsdl = getClass().getResource("/wsdl/soapheader.wsdl");
assertNotNull(wsdl);
SOAPHeaderService service = new SOAPHeaderService(wsdl, serviceName);
assertNotNull(service);
TestHeader proxy = service.getPort(portName, TestHeader.class);
try {
TestHeader1 val = new TestHeader1();
for (int idx = 0; idx < 2; idx++) {
TestHeader1Response returnVal = proxy.testHeader1(val, val);
assertNotNull(returnVal);
assertEquals(TestHeader1.class.getSimpleName(), returnVal.getResponseType());
}
} catch (UndeclaredThrowableException ex) {
throw (Exception) ex.getCause();
}
}
Aggregations