Main Page Namespace List Class Hierarchy Alphabetical List Compound List File List Namespace Members Compound Members File Members Related Pages

# TAO_EC_Reactive_ObserverStrategy Class Reference

A reactive observer strategy. More...

`#include <EC_ObserverStrategy.h>`

Inheritance diagram for TAO_EC_Reactive_ObserverStrategy:

[legend]
Collaboration diagram for TAO_EC_Reactive_ObserverStrategy:

[legend]
List of all members.

## Public Methods

| TAO_EC_Reactive_ObserverStrategy (TAO_EC_Event_Channel_Base *ec, ACE_Lock *lock)
| Constructor.
virtual | ~TAO_EC_Reactive_ObserverStrategy (void)
| Destructor.

## Protected Methods

virtual void | consumer_qos_update (TAO_EC_ProxyPushSupplier *supplier ACE_ENV_ARG_DECL)
| Recompute EC consumer subscriptions and send them out to all observers.
virtual void | supplier_qos_update (TAO_EC_ProxyPushConsumer *consumer ACE_ENV_ARG_DECL)
| Recompute EC supplier publications and send them out to all observers.
int | create_observer_map (Observer_Map &map ACE_ENV_ARG_DECL)
void | observer_not_exists (Observer_Entry &observer ACE_ENV_ARG_DECL)
| The observer doesn't exist anymore.

## Detailed Description

A reactive observer strategy.

This class simply keeps the information about the current list of observers, whenever the list of consumers and/or suppliers changes in queries the EC, computes the global subscription and/or publication list and sends the update message to all the observers. When an observer isn't reachable it is removed from the observer list.

## Memory Management

It assumes ownership of the <lock>, but not of the Event_Channel.

## Constructor & Destructor Documentation

ACE_INLINE TAO_EC_Reactive_ObserverStrategy::TAO_EC_Reactive_ObserverStrategy | ( | TAO_EC_Event_Channel_Base * | ec,
|  | ACE_Lock * | lock
| ) |

| Constructor.

TAO_EC_Reactive_ObserverStrategy::~TAO_EC_Reactive_ObserverStrategy | ( | void |  | ) | `[virtual]`

| Destructor.

## Member Function Documentation

void TAO_EC_Reactive_ObserverStrategy::consumer_qos_update | ( | TAO_EC_ProxyPushSupplier *supplier | ACE_ENV_ARG_DECL | ) | `[protected, virtual]`

| Recompute EC consumer subscriptions and send them out to all observers. Reimplemented from TAO_EC_Basic_ObserverStrategy.

int TAO_EC_Reactive_ObserverStrategy::create_observer_map | ( | Observer_Map &map | ACE_ENV_ARG_DECL | ) | `[protected]`

Copies all current observers into a map and passes it back to the caller through map.

Returns:
  Returns the size of the map.

void TAO_EC_Reactive_ObserverStrategy::observer_not_exists | ( | Observer_Entry &observer | ACE_ENV_ARG_DECL | ) | `[protected]`

| The observer doesn't exist anymore.

void TAO_EC_Reactive_ObserverStrategy::supplier_qos_update | ( | TAO_EC_ProxyPushConsumer *consumer | ACE_ENV_ARG_DECL | ) | `[protected, virtual]`

| Recompute EC supplier publications and send them out to all observers. Reimplemented from TAO_EC_Basic_ObserverStrategy.

The documentation for this class was generated from the following files:

- EC_ObserverStrategy.h
- EC_ObserverStrategy.cpp
- EC_ObserverStrategy.i