LArSoft
v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
|
A simple reference counter, keep track of a number of users. More...
#include "BulkAllocator.h"
Public Types | |
typedef unsigned int | Counter_t |
type of user counter More... | |
Public Member Functions | |
bool | hasUsers () const |
Returns whether there are currently users. More... | |
Counter_t | Count () const |
Returns the number of registered users. More... | |
void | AddUser () |
Adds a user to the users count. More... | |
bool | RemoveUser () |
Removed a user to the users count; returns false if no user yet. More... | |
Private Attributes | |
Counter_t | counter = 0 |
A simple reference counter, keep track of a number of users.
Definition at line 227 of file BulkAllocator.h.
typedef unsigned int lar::details::bulk_allocator::ReferenceCounter::Counter_t |
type of user counter
Definition at line 229 of file BulkAllocator.h.
|
inline |
Adds a user to the users count.
Definition at line 238 of file BulkAllocator.h.
References util::counter().
Referenced by lar::details::bulk_allocator::BulkAllocatorBase< T >::AddUser().
|
inline |
Returns the number of registered users.
Definition at line 235 of file BulkAllocator.h.
References util::counter().
|
inline |
Returns whether there are currently users.
Definition at line 232 of file BulkAllocator.h.
References util::counter().
Referenced by lar::details::bulk_allocator::BulkAllocatorBase< T >::RemoveUser().
|
inline |
Removed a user to the users count; returns false if no user yet.
Definition at line 241 of file BulkAllocator.h.
References util::counter().
Referenced by lar::details::bulk_allocator::BulkAllocatorBase< T >::RemoveUser().
|
private |
Definition at line 249 of file BulkAllocator.h.