Package com.adaptris.core
Interface ServiceCollection
-
- All Superinterfaces:
AdaptrisComponent
,java.util.Collection<Service>
,ComponentLifecycle
,ComponentLifecycleExtension
,ConfigComment
,EventHandlerAware
,java.lang.Iterable<Service>
,java.util.List<Service>
,MessageEventGenerator
,Service
,StateManagedComponent
- All Known Implementing Classes:
BranchingServiceCollection
,CloneMessageServiceList
,JdbcServiceList
,ServiceCollectionImp
,ServiceList
,ServiceListBase
public interface ServiceCollection extends Service, EventHandlerAware, java.util.List<Service>, ConfigComment
Defines behaviour common to collections of
Service
s. This class extendsService
and is thus aService
itself. Implementations may iterate through the collection in order, provide branching, etc.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addService(Service service)
Adds aService
to this collection.java.util.List<Service>
getServices()
Returns aList
of theService
s in this collection.void
handleException(Service service, AdaptrisMessage msg, java.lang.Exception e)
Handles any exceptions thrown from an embedded Service.-
Methods inherited from interface com.adaptris.core.AdaptrisComponent
getUniqueId
-
Methods inherited from interface com.adaptris.core.ComponentLifecycle
close, init, start, stop
-
Methods inherited from interface com.adaptris.core.ComponentLifecycleExtension
prepare
-
Methods inherited from interface com.adaptris.core.ConfigComment
getComments, setComments
-
Methods inherited from interface com.adaptris.core.EventHandlerAware
registerEventHandler
-
Methods inherited from interface java.util.List
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray
-
Methods inherited from interface com.adaptris.core.MessageEventGenerator
createName, createQualifier, isTrackingEndpoint
-
Methods inherited from interface com.adaptris.core.Service
continueOnFailure, doService, isBranching, setUniqueId
-
Methods inherited from interface com.adaptris.core.StateManagedComponent
changeState, requestClose, requestInit, requestStart, requestStop, retrieveComponentState
-
-
-
-
Method Detail
-
getServices
java.util.List<Service> getServices()
Returns a
List
of theService
s in this collection.- Returns:
- a
List
of theService
s in this collection
-
addService
void addService(Service service) throws CoreException
Adds a
Service
to this collection.- Parameters:
service
- theService
to add- Throws:
CoreException
- wrapping any underlying Exception that may occur
-
handleException
void handleException(Service service, AdaptrisMessage msg, java.lang.Exception e) throws ServiceException
Handles any exceptions thrown from an embedded Service.
- Parameters:
service
- service which threw the Exceptione
- the exception which was thrownmsg
- the message which caused the exception- Throws:
ServiceException
- wrapping the exception ifService.continueOnFailure()
is false
-
-