Quick Links:

bal | bbl | bdl | bsl

Public Member Functions

bdlcc::Deque< TYPE >::ConstProctor Class Reference

#include <bdlcc_deque.h>

List of all members.

Public Member Functions

 ConstProctor (const Deque< TYPE > *container=0)
 ~ConstProctor ()
void load (const Deque< TYPE > *container)
void release ()
const MonoDequeoperator-> () const
const MonoDequeoperator* () const
const TYPE & operator[] (size_type position) const
bool isNull () const

Detailed Description

template<class TYPE>
class bdlcc::Deque< TYPE >::ConstProctor

This class defines a proctor type that provides direct const access to the underlying bsl::deque contained in a Deque.

See Component bdlcc_deque


Constructor & Destructor Documentation

template<class TYPE>
bdlcc::Deque< TYPE >::ConstProctor::ConstProctor ( const Deque< TYPE > *  container = 0  )  [explicit]

Create a ConstProctor object to provide const access to the underlying bsl::deque contained in the optionally specified *container, locking containers mutex. If no container is specified, this object will be null.

template<class TYPE>
bdlcc::Deque< TYPE >::ConstProctor::~ConstProctor (  ) 

Release the lock on the mutex of the Deque that was provided at contstuction and destroy this Proctor object. The behavior is undefined if the Deque has been modified since the construction of this object.


Member Function Documentation

template<class TYPE>
void bdlcc::Deque< TYPE >::ConstProctor::load ( const Deque< TYPE > *  container  ) 

In the case where this Proctor has been released, attach this object to the specified container. If this object is already attached, release the previous object first. The behavior is undefined if 0 == container.

template<class TYPE>
void bdlcc::Deque< TYPE >::ConstProctor::release (  ) 

Release this proctor without destroying it. Afterward the destructor will have no effect. This may be called multiple times; only the first call has any effect;

template<class TYPE>
const MonoDeque* bdlcc::Deque< TYPE >::ConstProctor::operator-> (  )  const

Return a pointer to the bsl::deque contained in the Deque managed by this object. The behavior is undefined if this ConstProctor has been released.

template<class TYPE>
const MonoDeque& bdlcc::Deque< TYPE >::ConstProctor::operator* (  )  const

Return a reference to the bsl::deque managed by this Proctor object. The behavior is undefined if this ConstProctor has been released.

template<class TYPE>
const TYPE& bdlcc::Deque< TYPE >::ConstProctor::operator[] ( size_type  position  )  const

Return a reference providing non-modifiable access to the element at the specified position in the bsl::deque held by this proctor. The behavior is undefined unless position < size where size is the number of elements in that deque.

template<class TYPE>
bool bdlcc::Deque< TYPE >::ConstProctor::isNull (  )  const

Return true if this object is not associated with a Deque object.


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