OpenSDN source code
DBTableBase::ListenerInfo Class Reference
Collaboration diagram for DBTableBase::ListenerInfo:

Public Types

typedef vector< ChangeCallbackCallbackList
 
typedef vector< string > NameList
 
typedef vector< tbb::atomic< uint64_t > > StateCountList
 

Public Member Functions

 ListenerInfo (const string &table_name)
 
DBTableBase::ListenerId Register (ChangeCallback callback, const string &name)
 
void Unregister (ListenerId listener)
 
void RunNotify (DBTablePartBase *tpart, DBEntryBase *entry)
 
void AddToDBStateCount (ListenerId listener, int count)
 
uint64_t GetDBStateCount (ListenerId listener)
 
void FillListeners (vector< ShowTableListener > *listeners) const
 
bool empty () const
 
size_t size () const
 

Private Attributes

bool db_state_accounting_
 
CallbackList callbacks_
 
NameList names_
 
StateCountList state_count_
 
tbb::spin_rw_mutex rw_mutex_
 
boost::dynamic_bitset bmap_
 

Detailed Description

Definition at line 49 of file db_table.cc.

Member Typedef Documentation

◆ CallbackList

Definition at line 51 of file db_table.cc.

◆ NameList

typedef vector<string> DBTableBase::ListenerInfo::NameList

Definition at line 52 of file db_table.cc.

◆ StateCountList

typedef vector<tbb::atomic<uint64_t> > DBTableBase::ListenerInfo::StateCountList

Definition at line 53 of file db_table.cc.

Constructor & Destructor Documentation

◆ ListenerInfo()

DBTableBase::ListenerInfo::ListenerInfo ( const string &  table_name)
inlineexplicit

Definition at line 55 of file db_table.cc.

Member Function Documentation

◆ AddToDBStateCount()

void DBTableBase::ListenerInfo::AddToDBStateCount ( ListenerId  listener,
int  count 
)
inline

Definition at line 122 of file db_table.cc.

◆ empty()

bool DBTableBase::ListenerInfo::empty ( ) const
inline

Definition at line 148 of file db_table.cc.

◆ FillListeners()

void DBTableBase::ListenerInfo::FillListeners ( vector< ShowTableListener > *  listeners) const
inline

Definition at line 133 of file db_table.cc.

◆ GetDBStateCount()

uint64_t DBTableBase::ListenerInfo::GetDBStateCount ( ListenerId  listener)
inline

Definition at line 128 of file db_table.cc.

◆ Register()

DBTableBase::ListenerId DBTableBase::ListenerInfo::Register ( ChangeCallback  callback,
const string &  name 
)
inline

Definition at line 64 of file db_table.cc.

Here is the call graph for this function:

◆ RunNotify()

void DBTableBase::ListenerInfo::RunNotify ( DBTablePartBase tpart,
DBEntryBase entry 
)
inline

Definition at line 111 of file db_table.cc.

◆ size()

size_t DBTableBase::ListenerInfo::size ( ) const
inline

Definition at line 153 of file db_table.cc.

◆ Unregister()

void DBTableBase::ListenerInfo::Unregister ( ListenerId  listener)
inline

Definition at line 86 of file db_table.cc.

Member Data Documentation

◆ bmap_

boost::dynamic_bitset DBTableBase::ListenerInfo::bmap_
private

Definition at line 164 of file db_table.cc.

◆ callbacks_

CallbackList DBTableBase::ListenerInfo::callbacks_
private

Definition at line 160 of file db_table.cc.

◆ db_state_accounting_

bool DBTableBase::ListenerInfo::db_state_accounting_
private

Definition at line 159 of file db_table.cc.

◆ names_

NameList DBTableBase::ListenerInfo::names_
private

Definition at line 161 of file db_table.cc.

◆ rw_mutex_

tbb::spin_rw_mutex DBTableBase::ListenerInfo::rw_mutex_
mutableprivate

Definition at line 163 of file db_table.cc.

◆ state_count_

StateCountList DBTableBase::ListenerInfo::state_count_
private

Definition at line 162 of file db_table.cc.


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