class NamedCounter

Atomic counter with name. More...

Full nameTelEngine::NamedCounter
Definition#include <yateclass.h>
InheritsTelEngine::String [public ]
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods


Detailed Description

An atomic counter with an associated name

explicit  NamedCounter (const String& name)

NamedCounter

Constructor

Parameters:
nameName of the counter

inline bool  enabled ()

enabled

[const]

Check if the counter is enabled

Returns: True if the counter is enabled

inline void  enable (bool val)

enable

Enable or disable the counter

Parameters:
valTrue to enable counter, false to disable

int  inc ()

inc

Increment the counter

Returns: Post-increment value of the counter

int  dec ()

dec

Decrement the counter

Returns: Post-decrement value of the counter

inline int  count ()

count

[const]

Get the current value of the counter

Returns: Value of the counter


Generated by: paulc on bussard on Mon Feb 10 13:15:47 2014, using kdoc 2.0a54.