Class OutStreamSubstituteInterceptor
- java.lang.Object
-
- org.apache.cxf.phase.AbstractPhaseInterceptor<Message>
-
- org.openehealth.ipf.commons.ihe.ws.cxf.payload.OutStreamSubstituteInterceptor
-
- All Implemented Interfaces:
Interceptor<Message>
,PhaseInterceptor<Message>
public class OutStreamSubstituteInterceptor extends AbstractPhaseInterceptor<Message>
CXF interceptor that substitutes message output stream with a special wrapper that collects SOAP payload.- Author:
- Dmytro Rud
-
-
Constructor Summary
Constructors Constructor Description OutStreamSubstituteInterceptor()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static WrappedOutputStream
getStreamWrapper(Message message)
Retrieves the instance of stream wrapper installed by this interceptor.void
handleMessage(Message message)
-
Methods inherited from class org.apache.cxf.phase.AbstractPhaseInterceptor
addAfter, addAfter, addBefore, addBefore, getAdditionalInterceptors, getAfter, getBefore, getId, getPhase, handleFault, isGET, isRequestor, setAfter, setBefore
-
-
-
-
Method Detail
-
handleMessage
public void handleMessage(Message message)
-
getStreamWrapper
public static WrappedOutputStream getStreamWrapper(Message message)
Retrieves the instance of stream wrapper installed by this interceptor.- Parameters:
message
- CXF message which contains output stream as one of content types.- Returns:
- an instance of
WrappedOutputStream
. - Throws:
IllegalStateException
- when the stream wrapper instance could not be retrieved.
-
-