TAO_RTEvent  3.0.0
Public Member Functions | Public Attributes | Private Attributes | List of all members
TAO_EC_ProxyPushConsumer_Guard Class Reference

A Guard for the ProxyPushConsumer reference count. More...

#include <EC_ProxyConsumer.h>

Collaboration diagram for TAO_EC_ProxyPushConsumer_Guard:
Collaboration graph
[legend]

Public Member Functions

 TAO_EC_ProxyPushConsumer_Guard (ACE_Lock *lock, CORBA::ULong &refcount, TAO_EC_Event_Channel_Base *ec, TAO_EC_ProxyPushConsumer *proxy)
 Constructor. More...
 
 ~TAO_EC_ProxyPushConsumer_Guard ()
 Destructor. More...
 
bool locked () const
 Returns true if the reference count successfully acquired. More...
 

Public Attributes

TAO_EC_Supplier_Filterfilter
 

Private Attributes

ACE_Locklock_
 The lock used to protect the reference count. More...
 
CORBA::ULongrefcount_
 The reference count. More...
 
TAO_EC_ProxyPushConsumerproxy_
 The event channel used to destroy the proxy. More...
 
bool locked_
 

Detailed Description

A Guard for the ProxyPushConsumer reference count.

This is a helper class used in the implementation of ProxyPushConumer. It provides a Guard mechanism to increment the reference count on the proxy and its filter, eliminating the need to hold mutexes during long operations.

Constructor & Destructor Documentation

◆ TAO_EC_ProxyPushConsumer_Guard()

TAO_EC_ProxyPushConsumer_Guard::TAO_EC_ProxyPushConsumer_Guard ( ACE_Lock lock,
CORBA::ULong refcount,
TAO_EC_Event_Channel_Base ec,
TAO_EC_ProxyPushConsumer proxy 
)

Constructor.

◆ ~TAO_EC_ProxyPushConsumer_Guard()

TAO_EC_ProxyPushConsumer_Guard::~TAO_EC_ProxyPushConsumer_Guard ( )

Destructor.

Member Function Documentation

◆ locked()

bool TAO_EC_ProxyPushConsumer_Guard::locked ( void  ) const

Returns true if the reference count successfully acquired.

Member Data Documentation

◆ filter

TAO_EC_Supplier_Filter* TAO_EC_ProxyPushConsumer_Guard::filter

◆ lock_

ACE_Lock* TAO_EC_ProxyPushConsumer_Guard::lock_
private

The lock used to protect the reference count.

◆ locked_

bool TAO_EC_ProxyPushConsumer_Guard::locked_
private

This flag is set to true if the reference count was successfully acquired.

◆ proxy_

TAO_EC_ProxyPushConsumer* TAO_EC_ProxyPushConsumer_Guard::proxy_
private

The event channel used to destroy the proxy.

The proxy whose lifetime is controlled by the reference count

◆ refcount_

CORBA::ULong& TAO_EC_ProxyPushConsumer_Guard::refcount_
private

The reference count.


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