class Gambit::dep_bucket

An interface class for module dependencies. More…

#include <safety_bucket.hpp>

Inherits from Gambit::safety_bucket_base

Public Functions

Name
dep_bucket(str mym, str myf, str me, module_functor< TYPE > * functor_ptr_in =NULL, module_functor_common * dependent_functor_ptr_in =NULL)
Constructor for dep_bucket.
voidinitialize(module_functor< TYPE > * functor_ptr_in, module_functor_common * dependent_functor_ptr_in)
Initialize this bucket with a depedency functor pointer.
strmodule()
Get module name.
const TYPE &operator*() const
Dereference the dependency pointer stored as a safe_ptr.
const TYPE *operator->() const
Access is allowed to const member functions only.
safe_ptr< TYPE > &safe_pointer()
Get the safe_ptr.
booluse_thread_index(module_functor< TYPE > * f1, module_functor_common * f2)
Check if the thread index needs to be used to access the functor’s result.

Protected Attributes

Name
module_functor< TYPE > *_functor_ptr
safe_ptr< TYPE >_sptr
module_functor_common *_dependent_functor_ptr

Additional inherited members

Public Functions inherited from Gambit::safety_bucket_base

Name
safety_bucket_base(str myinfo)
Master constructor.
boolactive()
strname()
Get capability name.
strorigin()
Get name of origin (module/backend).

Protected Functions inherited from Gambit::safety_bucket_base

Name
voiddieGracefully() const
Failure message invoked when the user tries to access the object before it is initialized.

Protected Attributes inherited from Gambit::safety_bucket_base

Name
functor *_functor_base_ptr
bool_initialized
const strwhoami

Detailed Description

template <typename TYPE >
class Gambit::dep_bucket;

An interface class for module dependencies.

Public Functions Documentation

function dep_bucket

inline dep_bucket(
    str mym,
    str myf,
    str me,
    module_functor< TYPE > * functor_ptr_in =NULL,
    module_functor_common * dependent_functor_ptr_in =NULL
)

Constructor for dep_bucket.

function initialize

inline void initialize(
    module_functor< TYPE > * functor_ptr_in,
    module_functor_common * dependent_functor_ptr_in
)

Initialize this bucket with a depedency functor pointer.

function module

inline str module()

Get module name.

function operator*

inline const TYPE & operator*() const

Dereference the dependency pointer stored as a safe_ptr.

function operator->

inline const TYPE * operator->() const

Access is allowed to const member functions only.

function safe_pointer

inline safe_ptr< TYPE > & safe_pointer()

Get the safe_ptr.

function use_thread_index

static inline bool use_thread_index(
    module_functor< TYPE > * f1,
    module_functor_common * f2
)

Check if the thread index needs to be used to access the functor’s result.

Protected Attributes Documentation

variable _functor_ptr

module_functor< TYPE > * _functor_ptr;

variable _sptr

safe_ptr< TYPE > _sptr;

variable _dependent_functor_ptr

module_functor_common * _dependent_functor_ptr;

Updated on 2023-06-26 at 21:36:50 +0000