org.ow2.petals.component.framework.api.notification
Interface NotificationService

All Superinterfaces:
LifeCyle, StatusListener

public interface NotificationService
extends LifeCyle, StatusListener

This is the notification service which handle all notification related stuff.

Since:
2.0.4
Author:
chamerling - eBM WebSourcing

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.ow2.petals.component.framework.api.notification.LifeCyle
LifeCyle.STATE
 
Method Summary
 void addListener(StatusListener listener)
          Add a global listener which will react on notification subscription changes
 AsyncSender getAsyncSender(StatusListener listener)
          Get an asynchronous sender and pass it a listener to handle responses.
 NotificationBrokerController getNotificationBrokerController()
          The notification broker controller
 Sender getSender()
          The sender which is in charge of sending things through the service bus.
 void setActive(boolean status)
          Activate or unactivate the notifications feature.
 
Methods inherited from interface org.ow2.petals.component.framework.api.notification.LifeCyle
init, start, stop
 
Methods inherited from interface org.ow2.petals.component.framework.api.notification.StatusListener
onException, onRegistered, onSubscribed, onUnregistered, onUnsubscribed
 

Method Detail

setActive

void setActive(boolean status)
               throws PEtALSCDKException
Activate or unactivate the notifications feature. If it becomes active, it means that the component will register itself to the notification broker and that it will be able to send and receive notifications. On the other case, unregister itself so notification can not be send nd/or received.

Throws:
PEtALSCDKException

getNotificationBrokerController

NotificationBrokerController getNotificationBrokerController()
The notification broker controller

Returns:

getSender

Sender getSender()
The sender which is in charge of sending things through the service bus.

Returns:

addListener

void addListener(StatusListener listener)
Add a global listener which will react on notification subscription changes

Parameters:
listener -

getAsyncSender

AsyncSender getAsyncSender(StatusListener listener)
Get an asynchronous sender and pass it a listener to handle responses. All the calls are fire and forget ones in a total asynchronous mode. A new instance of the AsyncSender is returned on each call.

Parameters:
listener -
Returns:


Copyright © 2005-2012 Petals Link (EBM Websourcing). All Rights Reserved.