Package com.adaptris.core.services
Class InputOutputService
- java.lang.Object
-
- com.adaptris.core.ServiceImp
-
- com.adaptris.core.services.InputOutputService
-
- All Implemented Interfaces:
AdaptrisComponent
,ComponentLifecycle
,ComponentLifecycleExtension
,MessageEventGenerator
,Service
,StateManagedComponent
@ComponentProfile(summary="Force IO to happen on a message.", tag="service", since="3.7.1") public class InputOutputService extends ServiceImp
Forces IO to happen from the message inputstream to outputstream.This service is only included for completeness as there are only a limited number of use-cases for it. For instance, if your message-factory is a
ZipFileBackedMessageFactory
(mode=Uncompress
) and you do not do any IO on the message in the workflow then the message may still be compressed when you write it out to the filesystem. Using this service simply forces IO to happen on the message.
-
-
Field Summary
-
Fields inherited from class com.adaptris.core.ServiceImp
log
-
-
Constructor Summary
Constructors Constructor Description InputOutputService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
closeService()
void
doService(AdaptrisMessage msg)
Apply the service to the message.protected void
initService()
void
prepare()
Prepare for initialisation.-
Methods inherited from class com.adaptris.core.ServiceImp
changeState, close, continueOnFailure, createName, createQualifier, getContinueOnFail, getIsTrackingEndpoint, getUniqueId, init, isBranching, isTrackingEndpoint, requestClose, requestInit, requestStart, requestStop, retrieveComponentState, setContinueOnFail, setIsTrackingEndpoint, setUniqueId, start, stop
-
-
-
-
Method Detail
-
doService
public void doService(AdaptrisMessage msg) throws ServiceException
Description copied from interface:Service
Apply the service to the message.
- Parameters:
msg
- theAdaptrisMessage
to process- Throws:
ServiceException
- wrapping any underlyingException
s
-
prepare
public void prepare() throws CoreException
Description copied from interface:ComponentLifecycleExtension
Prepare for initialisation.- Throws:
CoreException
-
initService
protected void initService() throws CoreException
- Specified by:
initService
in classServiceImp
- Throws:
CoreException
-
closeService
protected void closeService()
- Specified by:
closeService
in classServiceImp
-
-