17 #ifndef MBED_CALLCHAIN_H 18 #define MBED_CALLCHAIN_H 20 #include "core-util/FunctionPointer.h" 61 typedef mbed::util::FunctionPointer* pFunctionPointer_t;
79 pFunctionPointer_t
add(
void (*
function)(
void));
90 pFunctionPointer_t
add(T *tptr,
void (T::*mptr)(
void)) {
91 return common_add(
new mbed::util::FunctionPointer(tptr, mptr));
101 pFunctionPointer_t
add_front(
void (*
function)(
void));
112 pFunctionPointer_t
add_front(T *tptr,
void (T::*mptr)(
void)) {
113 return common_add_front(
new mbed::util::FunctionPointer(tptr, mptr));
127 pFunctionPointer_t
get(
int i)
const;
136 int find(pFunctionPointer_t f)
const;
149 bool remove(pFunctionPointer_t f);
155 #ifdef MBED_OPERATORS 156 void operator ()(
void) {
159 pFunctionPointer_t operator [](
int i)
const {
166 pFunctionPointer_t common_add(pFunctionPointer_t pf);
167 pFunctionPointer_t common_add_front(pFunctionPointer_t pf);
169 pFunctionPointer_t* _chain;
void call()
Definition: CallChain.cpp:76
pFunctionPointer_t add_front(void(*function)(void))
Definition: CallChain.cpp:35
void clear()
Definition: CallChain.cpp:56
pFunctionPointer_t add(T *tptr, void(T::*mptr)(void))
Definition: CallChain.h:90
CallChain(int size=4)
Definition: CallChain.cpp:22
int size() const
Definition: CallChain.cpp:39
pFunctionPointer_t add(void(*function)(void))
Definition: CallChain.cpp:31
int find(pFunctionPointer_t f) const
Definition: CallChain.cpp:49
pFunctionPointer_t add_front(T *tptr, void(T::*mptr)(void))
Definition: CallChain.h:112
Definition: CallChain.h:63