use of org.apache.cxf.jca.cxf.CXFConnectionRequestInfo in project cxf by apache.
the class OutBoundConnectionTest method testGetConnectionFromSEI.
@Test
@org.junit.Ignore
public void testGetConnectionFromSEI() throws Exception {
CXFConnectionRequestInfo requestInfo = new CXFConnectionRequestInfo();
requestInfo.setInterface(Greeter.class);
requestInfo.setAddress("http://localhost:" + PORT + "/SoapContext/SoapPort");
ManagedConnectionFactory factory = new ManagedConnectionFactoryImpl();
ManagedConnection mc = factory.createManagedConnection(null, requestInfo);
Object client = mc.getConnection(null, requestInfo);
verifyResult(client);
}
use of org.apache.cxf.jca.cxf.CXFConnectionRequestInfo in project cxf by apache.
the class OutBoundConnectionTest method testBasicConnection.
@Test
@org.junit.Ignore
public void testBasicConnection() throws Exception {
URL wsdl = getClass().getResource("/wsdl/hello_world.wsdl");
assertNotNull(wsdl);
SOAPService service = new SOAPService(wsdl, serviceName);
assertNotNull(service);
CXFConnectionRequestInfo cri = new CXFConnectionRequestInfo(Greeter.class, wsdl, service.getServiceName(), portName);
cri.setAddress("http://localhost:" + PORT + "/SoapContext/SoapPort");
ManagedConnectionFactory managedFactory = new ManagedConnectionFactoryImpl();
Subject subject = new Subject();
ManagedConnection mc = managedFactory.createManagedConnection(subject, cri);
Object o = mc.getConnection(subject, cri);
// test for the Object hash()
try {
o.hashCode();
o.toString();
} catch (WebServiceException ex) {
fail("The connection object should support Object method");
}
verifyResult(o);
}
use of org.apache.cxf.jca.cxf.CXFConnectionRequestInfo in project cxf by apache.
the class CXFConnectionParam method equals.
public boolean equals(java.lang.Object other) {
boolean result = false;
if (other instanceof CXFConnectionRequestInfo) {
CXFConnectionRequestInfo cri = (CXFConnectionRequestInfo) other;
result = areEquals(iface, cri.getInterface()) && areEquals(wsdlLocation, cri.getWsdlLocation()) && areEquals(serviceName, cri.getServiceName()) && areEquals(portName, cri.getPortName()) && areEquals(address, cri.getAddress());
}
return result;
}
Aggregations