public class PublishSubscribeCommunicationManager
extends java.lang.Object
Constructor and Description |
---|
PublishSubscribeCommunicationManager(NodeConnection nodeConnection,
GroupCommunicationManager groupCommunicationManager)
Default contructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addPublishSubscribeListener(PublishSubscribeListener pubsubListener)
Adds a listenter to the Publish-Subscribe Protocol.
|
void |
finalize() |
void |
publish(InformationData informationData)
Publishes a new InformationData in the Publish-Subscribe platform.
|
void |
registerPublisher(Information informationClass)
Method used to register a publisher, informing the system of a available
type of information.
|
void |
removePublishSubscribeListener(PublishSubscribeListener pubsubListener)
Removes a listenter to the Publish-Subscribe Protocol.
|
SubscriptionIdentification |
subscribe(Subscription subscription,
SubscriptionListener listener)
Method used to register a subscriber, informing the system about the
interest of a type of information.
|
void |
unregisterPublisher(Information informationClass)
Method used to unregister a publisher.
|
boolean |
unsubscribe(SubscriptionIdentification subscriptionId)
Method used to unregister a subscriber.
|
public PublishSubscribeCommunicationManager(NodeConnection nodeConnection, GroupCommunicationManager groupCommunicationManager)
nodeConnection
- groupCommunicationManager
- public void finalize()
finalize
in class java.lang.Object
public void registerPublisher(Information informationClass) throws java.io.IOException
informationClass
- the information class that can be producedjava.io.IOException
public void unregisterPublisher(Information informationClass) throws java.io.IOException
informationClass
- the information class that can be producedjava.io.IOException
public void publish(InformationData informationData) throws java.io.IOException
informationData
- java.io.IOException
public SubscriptionIdentification subscribe(Subscription subscription, SubscriptionListener listener) throws java.io.IOException
subscription
- listener
- java.io.IOException
public boolean unsubscribe(SubscriptionIdentification subscriptionId)
subscriptionId
- public void addPublishSubscribeListener(PublishSubscribeListener pubsubListener)
pubsubListener
- the listener.public void removePublishSubscribeListener(PublishSubscribeListener pubsubListener)
pubsubListener
- the listener.