public class AbstractEntityAdjunct.BasicSubscriptionSupport extends java.lang.Object implements BrooklynObjectInternal.SubscriptionSupportInternal
Constructor and Description |
---|
BasicSubscriptionSupport() |
Modifier and Type | Method and Description |
---|---|
<T> SubscriptionHandle |
subscribe(Entity producer,
Sensor<T> sensor,
SensorEventListener<? super T> listener)
Allow us to subscribe to data from a
Sensor on another entity. |
<T> SubscriptionHandle |
subscribe(java.util.Map<java.lang.String,?> flags,
Entity producer,
Sensor<T> sensor,
SensorEventListener<? super T> listener)
Allow us to subscribe to data from a
Sensor on another entity. |
<T> SubscriptionHandle |
subscribeToChildren(Entity producerParent,
Sensor<T> sensor,
SensorEventListener<? super T> listener) |
<T> SubscriptionHandle |
subscribeToMembers(Group producerGroup,
Sensor<T> sensor,
SensorEventListener<? super T> listener) |
boolean |
unsubscribe(Entity producer)
Unsubscribes from the given producer.
|
boolean |
unsubscribe(Entity producer,
SubscriptionHandle handle)
Unsubscribes the given handle.
|
boolean |
unsubscribe(SubscriptionHandle handle)
Unsubscribes the given handle.
|
void |
unsubscribeAll() |
public <T> SubscriptionHandle subscribe(Entity producer, Sensor<T> sensor, SensorEventListener<? super T> listener)
BrooklynObject.SubscriptionSupport
Sensor
on another entity.subscribe
in interface BrooklynObject.SubscriptionSupport
SubscriptionManager.subscribe(Map, Entity, Sensor, SensorEventListener)
public <T> SubscriptionHandle subscribe(java.util.Map<java.lang.String,?> flags, Entity producer, Sensor<T> sensor, SensorEventListener<? super T> listener)
BrooklynObject.SubscriptionSupport
Sensor
on another entity.subscribe
in interface BrooklynObject.SubscriptionSupport
SubscriptionManager.subscribe(Map, Entity, Sensor, SensorEventListener)
public <T> SubscriptionHandle subscribeToMembers(Group producerGroup, Sensor<T> sensor, SensorEventListener<? super T> listener)
subscribeToMembers
in interface BrooklynObject.SubscriptionSupport
SubscriptionManager.subscribeToMembers(Group, Sensor, SensorEventListener)
public <T> SubscriptionHandle subscribeToChildren(Entity producerParent, Sensor<T> sensor, SensorEventListener<? super T> listener)
subscribeToChildren
in interface BrooklynObject.SubscriptionSupport
SubscriptionManager.subscribeToChildren(Map, Entity, Sensor, SensorEventListener)
public boolean unsubscribe(Entity producer)
BrooklynObject.SubscriptionSupport
unsubscribe
in interface BrooklynObject.SubscriptionSupport
SubscriptionContext.unsubscribe(SubscriptionHandle)
public boolean unsubscribe(Entity producer, SubscriptionHandle handle)
BrooklynObject.SubscriptionSupport
unsubscribe
in interface BrooklynObject.SubscriptionSupport
SubscriptionContext.unsubscribe(SubscriptionHandle)
public boolean unsubscribe(SubscriptionHandle handle)
BrooklynObject.SubscriptionSupport
BrooklynObject.SubscriptionSupport.unsubscribe(Entity, SubscriptionHandle)
unsubscribe
in interface BrooklynObject.SubscriptionSupport
public void unsubscribeAll()
unsubscribeAll
in interface BrooklynObjectInternal.SubscriptionSupportInternal