CMS 3D CMS Logo

stor::BaseCounter Class Reference

#include <EventFilter/StorageManager/interface/BaseCounter.h>

Inheritance diagram for stor::BaseCounter:

stor::ForeverCounter stor::RollingIntervalCounter stor::RollingSampleCounter

List of all members.

Static Public Member Functions

static double getCurrentTime ()
 Returns the current time as a double.


Detailed Description

Definition at line 17 of file BaseCounter.h.


Member Function Documentation

double BaseCounter::getCurrentTime (  )  [static]

Returns the current time as a double.

The value corresponds to the number of seconds since the epoch (including a fractional part good to the microsecond level). A negative value indicates that an error occurred when fetching the time from the operating system.

Definition at line 17 of file BaseCounter.cc.

References StDecayID::status.

Referenced by stor::StorageManager::addMeasurement(), stor::SMProxyServer::addOutMeasurement(), stor::ForeverCounter::addSample(), stor::ConsumerPipe::ConsumerPipe(), stor::SMProxyServer::defaultWebPage(), stor::RollingSampleCounter::dumpData(), stor::RollingIntervalCounter::dumpData(), stor::RateLimiter::dumpData(), stor::SMProxyServer::eventServerWebPage(), stor::StorageManager::eventServerWebPage(), edm::ServiceManager::get_stats(), stor::RateLimiter::getAllowedConsumersFromList(), stor::EventServer::processEvent(), stor::ConsumerPipe::putEvent(), stor::RollingSampleCounter::shuffleBins(), and stor::ConsumerPipe::wantsEvent().

00018 {
00019   double now = -1.0;
00020   struct timeval timeStruct;
00021   int status = gettimeofday(&timeStruct, 0);
00022   if (status == 0) {
00023     now = ((double) timeStruct.tv_sec) +
00024       (((double) timeStruct.tv_usec) / 1000000.0);
00025   }
00026   return now;
00027 }


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:52:48 2009 for CMSSW by  doxygen 1.5.4