|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.bitrepository.service.contributor.AbstractContributorMediator
public abstract class AbstractContributorMediator
Defines the general functionality for handling a set of requests. Does this by delegating the
handling of the specific request to appropriate RequestHandler
s.
Constructor Summary | |
---|---|
AbstractContributorMediator(MessageBus messageBus)
Constructor. |
Method Summary | |
---|---|
void |
close()
Closes the mediator by removing all the message handler. |
protected abstract RequestHandler[] |
createListOfHandlers()
|
protected abstract ContributorContext |
getContext()
|
protected abstract void |
handleRequest(MessageRequest request,
RequestHandler handler)
Make the inheriting class create the environment for safely handling the request. |
void |
start()
Starts listening for requests. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AbstractContributorMediator(MessageBus messageBus)
messageBus
- The messagebus for this mediator.Method Detail |
---|
public final void start()
start
in interface ContributorMediator
protected abstract RequestHandler[] createListOfHandlers()
RequestHandler
s used for this contributor.protected abstract ContributorContext getContext()
protected abstract void handleRequest(MessageRequest request, RequestHandler handler)
request
- The request to handle.handler
- The handler for the request.public void close()
close
in interface ContributorMediator
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |