copasi API  0.1
Public Member Functions | Static Public Member Functions
CCopasiTimeVariable Class Reference

#include <CopasiTime.h>

List of all members.

Public Member Functions

 CCopasiTimeVariable ()
 CCopasiTimeVariable (const CCopasiTimeVariable &src)
 CCopasiTimeVariable (const C_INT64 &value)
 ~CCopasiTimeVariable ()
CCopasiTimeVariable operator+ (const CCopasiTimeVariable &value)
CCopasiTimeVariable operator- (const CCopasiTimeVariable &value)
CCopasiTimeVariableoperator= (const CCopasiTimeVariable &rhs)
CCopasiTimeVariableoperator= (const C_INT64 &value)
bool operator< (const CCopasiTimeVariable &value)
std::string isoFormat () const
C_INT64 getMicroSeconds (const bool &bounded=false) const
C_INT64 getMilliSeconds (const bool &bounded=false) const
C_INT64 getSeconds (const bool &bounded=false) const
C_INT64 getMinutes (const bool &bounded=false) const
C_INT64 getHours (const bool &bounded=false) const
C_INT64 getDays () const

Static Public Member Functions

static CCopasiTimeVariable getCurrentWallTime ()
static CCopasiTimeVariable getCPUTime ()
static std::string LL2String (const C_INT64 &value, const C_INT32 &digits=0)

Detailed Description

This class is for handling execution time related values. static methods for retreiving wall clock and CPU time are provided.


Constructor & Destructor Documentation

CCopasiTimeVariable::CCopasiTimeVariable ( )

Default constructor.

CCopasiTimeVariable::CCopasiTimeVariable ( const CCopasiTimeVariable src)

Copy constructor.

Parameters:
constCCopasiTimeVariable & src
CCopasiTimeVariable::CCopasiTimeVariable ( const C_INT64 &  value)

Specific constructor from a C_INT64 value.

Parameters:
constC_INT64 & value
CCopasiTimeVariable::~CCopasiTimeVariable ( )

Destructor.


Member Function Documentation

CCopasiTimeVariable CCopasiTimeVariable::getCPUTime ( ) [static]

Retrieve the current cpu time used since the start of the process.

Returns:
CCopasiTimeVariable time
CCopasiTimeVariable CCopasiTimeVariable::getCurrentWallTime ( ) [static]

Retrieve the current wall clock time in micro seconds since 1970-01-01:00:00:00.0

Returns:
CCopasiTimeVariable time
C_INT64 CCopasiTimeVariable::getDays ( ) const

Retrieve the time in days.

Parameters:
constbool & bounded (default: false)
Returns:
C_INT64 days
C_INT64 CCopasiTimeVariable::getHours ( const bool &  bounded = false) const

Retrieve the time in hours. If bounded is true 0 <= hours < 24

Parameters:
constbool & bounded (default: false)
Returns:
C_INT64 hours
C_INT64 CCopasiTimeVariable::getMicroSeconds ( const bool &  bounded = false) const

Retrieve the time in micro seconds. If bounded is true 0 <= microSeconds < 1000

Parameters:
constbool & bounded (default: false)
Returns:
C_INT64 microSeconds
C_INT64 CCopasiTimeVariable::getMilliSeconds ( const bool &  bounded = false) const

Retrieve the time in milli seconds. If bounded is true 0 <= milliSeconds < 1000

Parameters:
constbool & bounded (default: false)
Returns:
C_INT64 milliSeconds
C_INT64 CCopasiTimeVariable::getMinutes ( const bool &  bounded = false) const

Retrieve the time in minutes. If bounded is true 0 <= minutes < 60

Parameters:
constbool & bounded (default: false)
Returns:
C_INT64 minutes
C_INT64 CCopasiTimeVariable::getSeconds ( const bool &  bounded = false) const

Retrieve the time in seconds. If bounded is true 0 <= seconds < 60

Parameters:
constbool & bounded (default: false)
Returns:
C_INT64 seconds
std::string CCopasiTimeVariable::isoFormat ( ) const

Create a iso formated string (D:HH:MM:SS.ssssss)

Returns:
std::string
std::string CCopasiTimeVariable::LL2String ( const C_INT64 &  value,
const C_INT32 &  digits = 0 
) [static]

Helper function to convert a C_INT32 to a std::string. If the number of digits is non zero the value is padded with zeros.

Parameters:
constC_INT64 & value
constC_INT32 & digits (default: 0)
Returns:
std::string
CCopasiTimeVariable CCopasiTimeVariable::operator+ ( const CCopasiTimeVariable value)

Operator + for adding CCopasiTimeVariables

Parameters:
constCCopasiTimeVariable & value
Returns:
CCopasiTimeVariable sum
CCopasiTimeVariable CCopasiTimeVariable::operator- ( const CCopasiTimeVariable value)

Operator - for subtracting CCopasiTimeVariables

Parameters:
constCCopasiTimeVariable & value
Returns:
CCopasiTimeVariable difference
bool CCopasiTimeVariable::operator< ( const CCopasiTimeVariable value)

Coparison operator <

Parameters:
constCCopasiTimeVariable & value
Returns:
bool isLess
CCopasiTimeVariable & CCopasiTimeVariable::operator= ( const CCopasiTimeVariable rhs)

Assignement operator

Parameters:
constCCopasiTimeVariable & rhs
Returns:
CCopasiTimeVariable & this
CCopasiTimeVariable & CCopasiTimeVariable::operator= ( const C_INT64 &  value)

Assignement operator assigning a C_INT64 value to a CCopasiTimeVariable

Parameters:
constCCopasiTimeVariable & rhs
Returns:
CCopasiTimeVariable & this

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines