CMS 3D CMS Logo

Functions | Variables

/data/refman/pasoursint/CMSSW_5_2_9/src/Utilities/StorageFactory/src/StorageAccount.cc File Reference

#include "Utilities/StorageFactory/interface/StorageAccount.h"
#include <boost/thread/mutex.hpp>
#include <sstream>
#include <unistd.h>

Go to the source code of this file.

Functions

static std::string d2str (double d)
static std::string i2str (int i)
static double timeRealNanoSecs (void)

Variables

boost::mutex s_mutex
StorageAccount::StorageStats s_stats

Function Documentation

static std::string d2str ( double  d) [static]

Definition at line 28 of file StorageAccount.cc.

References lumiQTWidget::t.

                                 {
  std::ostringstream t;
  t << d;
  return t.str();
}
static std::string i2str ( int  i) [static]

Definition at line 22 of file StorageAccount.cc.

References i, and lumiQTWidget::t.

                              {
  std::ostringstream t;
  t << i;
  return t.str();
}
static double timeRealNanoSecs ( void  ) [static]

Definition at line 9 of file StorageAccount.cc.

References CLOCK_REALTIME.

Referenced by StorageAccount::Stamp::tick().

                                      {
#if _POSIX_TIMERS > 0
  struct timespec tm;
  if (clock_gettime(CLOCK_REALTIME, &tm) == 0)
    return tm.tv_sec * 1e9 + tm.tv_nsec;
#else
  struct timeval tm;
  if (gettimeofday(&tm, 0) == 0)
    return tm.tv_sec * 1e9 + tm.tv_usec * 1e3;
#endif
  return 0;
}

Variable Documentation