Per the Endpoint contract, you can't exactly create a Endpoint with just an
interface unfortunately.
However, that doesn't mean CXF can't do it :-) Try something like this:
sf = new JaxWsServiceFactoryBean();
sf.setServiceClass(YourServiceInterface.class);
sf.getServiceFactory().setInvoker(new BeanInvoker(new ImplNumberOne());
sf.setAddress("/yourService1"
sf.create();
You can also write your own invoker which does something completely
different with the objects if you really want to. Does that helps?
- Dan
On 7/9/07, Dan Connelly <[EMAIL PROTECTED]> wrote:
A JAX-WS Endpoint must be created using a service implementation.
A (Microsoft) WCF Endpoint, on the other hand, is created with an SEI
(C# interface), not an implementation. This allows multiple impls of
the same service interface to be reached through the WCF Endpoint. The
Dispatcher, which is configured separately, has rules for invoking the
desired implementation.
It seems to me that Microsoft got it right. Does anyone want to
comment on that?
Why is there no DispatchingInvoker class in CXF as a convenience when
the user needs a Dispatcher? Is there a sample showing the coding for
a dispatching Invoker?
-- Dan Connelly
--
Dan Diephouse
Envoi Solutions
http://envoisolutions.com | http://netzooid.com/blog