Lumiera
0.pre.03
»edit your freedom«
|
A Mock functor, logging all invocations into the EventLog.
Definition at line 239 of file activity-detector.hpp.
Public Member Functions | |
DiagnosticFun (string id, EventLog &masterLog, uint const &invocationSeqNr) | |
template<class FUN > | |
DiagnosticFun && | implementedAs (FUN &&customImpl) |
use the given λ to provide (optional) implementation logic | |
operator string () const | |
RET | operator() (ARGS ...args) const |
mock function call operator: logs all invocations | |
template<typename VAL > | |
DiagnosticFun && | returning (VAL &&riggedResponse) |
prepare a response value to return from the mock invocation | |
Private Types | |
using | ImplFun = std::function< RET(ARGS...)> |
using | RetVal = lib::wrapper::ItemWrapper< RET > |
Private Attributes | |
string | id_ |
ImplFun | implFun_ |
EventLog * | log_ |
RetVal | retVal_ |
uint const * | seqNr_ |