RAII wrapper for tracking force calls over a scope. More...
#include <ForceCallTimer.h>
Public Member Functions | |
| ForceCallTimer (size_t &target, const Potential &pot) | |
| ~ForceCallTimer () | |
| ForceCallTimer (const ForceCallTimer &)=delete | |
| ForceCallTimer & | operator= (const ForceCallTimer &)=delete |
Private Attributes | |
| size_t & | target_ |
| const Potential & | pot_ |
| size_t | initial_ |
RAII wrapper for tracking force calls over a scope.
Usage: { ForceCallTimer timer(targetCounter, <em>pot); / work */ } On destruction, adds the force calls pot evaluated in the scope to targetCounter. The potential's own counter is read, so the count holds whichever registry the potential charges.
Definition at line 22 of file ForceCallTimer.h.
|
inline |
Definition at line 28 of file ForceCallTimer.h.
|
inline |
Definition at line 30 of file ForceCallTimer.h.
|
delete |
|
delete |
|
private |
Definition at line 25 of file ForceCallTimer.h.
|
private |
Definition at line 24 of file ForceCallTimer.h.
|
private |
Definition at line 23 of file ForceCallTimer.h.