Package com.sun.xml.ws.server
Class InvokerTube<T>
- All Implemented Interfaces:
Pipe,Tube,EndpointAwareTube,InvokerSource<Invoker>
- Direct Known Subclasses:
ProviderInvokerTube,SEIInvokerTube
Base code for
ProviderInvokerTube and SEIInvokerTube.
This hides InstanceResolver and performs a set up
necessary for WebServiceContext to correctly.
- Author:
- Kohsuke Kawaguchi
-
Field Summary
Fields inherited from class com.sun.xml.ws.server.sei.InvokerTube
invoker -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal AbstractTubeImplcopy(TubeCloner cloner) processRequest() and processResponse() do not share any instance variables while processing the request.static PacketThis method can be called while the user service is servicing the request synchronously, to obtain the current request packet.protected WSEndpointfinal InvokergetInvoker(Packet request) Returns theInvokerobject that serves the request.voidInvoked before the last copy of the pipeline is about to be discarded, to giveTubes a chance to clean up any resources.voidsetEndpoint(WSEndpoint endpoint) Setter for WSEndpoint holding this tubeMethods inherited from class com.sun.xml.ws.api.pipe.helper.AbstractTubeImpl
copy, doInvoke, doInvokeAndForget, doReturnWith, doSuspend, doSuspend, doSuspend, doSuspend, doThrow, doThrow, processMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.sun.xml.ws.api.pipe.Tube
processException, processRequest, processResponse
-
Constructor Details
-
InvokerTube
-
-
Method Details
-
setEndpoint
Description copied from interface:EndpointAwareTubeSetter for WSEndpoint holding this tube- Specified by:
setEndpointin interfaceEndpointAwareTube- Parameters:
endpoint- WSEndpoint holding this tube
-
getEndpoint
-
getInvoker
Returns theInvokerobject that serves the request.- Specified by:
getInvokerin interfaceInvokerSource<T>- Overrides:
getInvokerin classInvokerTube<Invoker>- Parameters:
request- Packet for request- Returns:
- Selected invoker
-
copy
processRequest() and processResponse() do not share any instance variables while processing the request.InvokerTubeis stateless and terminal, so no need to create copies.- Specified by:
copyin interfaceTube- Specified by:
copyin classAbstractTubeImpl- Parameters:
cloner- Use this object (in particular itsTubeCloner.copy(Tube)method to clone other pipe references you have in your pipe. SeeTubeClonerfor more discussion about why.- Returns:
- always non-null
Tube.
-
preDestroy
public void preDestroy()Description copied from interface:TubeInvoked before the last copy of the pipeline is about to be discarded, to giveTubes a chance to clean up any resources.This can be used to invoke
PreDestroylifecycle methods on user handler. The invocation of it is optional on the client side, but mandatory on the server side.When multiple copies of pipelines are created, this method is called only on one of them.
- Specified by:
preDestroyin interfacePipe- Specified by:
preDestroyin interfaceTube
-
getCurrentPacket
This method can be called while the user service is servicing the request synchronously, to obtain the current request packet.This is primarily designed for
StatefulInstanceResolver. Use with care.
-