|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.xml.ws.api.pipe.TransportPipeFactory
public abstract class TransportPipeFactory
Factory for transport pipes that enables transport pluggability.
At runtime, on the client side, JAX-WS (more specifically the default PipelineAssembler
of JAX-WS client runtime) relies on this factory to create a suitable transport Pipe
that can handle the given endpoint address
.
JAX-WS extensions that provide additional transport support can
extend this class and implement the doCreate(com.sun.xml.ws.api.pipe.ClientPipeAssemblerContext)
method.
They are expected to check the scheme of the endpoint address
(and possibly some other settings from bindings), and create
their transport pipe implementations accordingly.
For example,
class MyTransportPipeFactoryImpl { Pipe doCreate(...) { String scheme = address.getURI().getScheme(); if(scheme.equals("foo")) return new MyTransport(...); else return null; } }
TransportPipeFactory
look-up follows the standard service
discovery mechanism, so you need
META-INF/services/com.sun.xml.ws.api.pipe.TransportPipeFactory
.
One of the JAX-WS operation mode is supposedly where it doesn't have no WSDL whatsoever. How do we identify the endpoint in such case?
StandalonePipeAssembler
Constructor Summary | |
---|---|
TransportPipeFactory()
|
Method Summary | |
---|---|
static Pipe |
create(ClassLoader classLoader,
ClientPipeAssemblerContext context)
Deprecated. Use TransportTubeFactory.create(ClassLoader, ClientTubeAssemblerContext) |
abstract Pipe |
doCreate(ClientPipeAssemblerContext context)
Creates a transport Pipe for the given port, if this factory can do so,
or return null. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TransportPipeFactory()
Method Detail |
---|
public abstract Pipe doCreate(@NotNull ClientPipeAssemblerContext context)
Pipe
for the given port, if this factory can do so,
or return null.
context
- Object that captures various contextual information
that can be used to determine the pipeline to be assembled.
TransportPipeFactory
s
that can. Or non-null.
javax.xml.ws.WebServiceException
- if this factory is capable of creating a transport pipe but some fatal
error prevented it from doing so. This exception will be propagated
back to the user application, and no further TransportPipeFactory
s
are consulted.public static Pipe create(@Nullable ClassLoader classLoader, @NotNull ClientPipeAssemblerContext context)
TransportTubeFactory.create(ClassLoader, ClientTubeAssemblerContext)
PipelineAssemblerFactory
s and create
a suitable PipelineAssembler
.
classLoader
- used to locate META-INF/servces
files.
PipelineAssembler
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |