#include "nrp_general_library/utils/nrp_exceptions.h"
#include "nrp_general_library/utils/time_utils.h"
Functions | |
SimulationTime | toSimulationTimeFromSeconds (double time) |
Converts floating-point seconds into SimulationTime. More... | |
double | getRoundedRunTimeMs (const SimulationTime runTime, const float simulationResolutionMs) |
Calculates simulation run time rounded to milliseconds, accounting for given resolution. More... | |
std::string | getTimestamp () |
returns the current local time as a string in the format: YYMMDD-hhmmss-pid, being pid the pid of the calling process More... | |
double getRoundedRunTimeMs | ( | const SimulationTime | runTime, |
const float | simulationResolutionMs | ||
) |
Calculates simulation run time rounded to milliseconds, accounting for given resolution.
runTime | Simulation run time that will be rounded |
simulationResolutionMs | Simulation resolution in milliseconds |
NRPException | When simulation run time is smaller than simulation resolution |
std::string getTimestamp | ( | ) |
returns the current local time as a string in the format: YYMMDD-hhmmss-pid, being pid the pid of the calling process
SimulationTime toSimulationTimeFromSeconds | ( | double | time | ) |
Converts floating-point seconds into SimulationTime.
time | The value to be converted |