Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TTimeStamp Class Reference

The TTimeStamp encapsulates seconds and ns since EPOCH.

This extends (and isolates) struct timespec

struct timespec
{
time_t tv_sec; // seconds
long tv_nsec; // nanoseconds
}
time_t seconds is relative to Jan 1, 1970 00:00:00 UTC

No accounting of leap seconds is made.

Due to ROOT/CINT limitations TTimeStamp does not explicitly hold a timespec struct; attempting to do so means the Streamer must be hand written. Instead we have chosen to simply contain similar fields within the private area of this class.

NOTE: the use of time_t (and its default implementation as a 32 int) implies overflow conditions occurs somewhere around Jan 18, 19:14:07, 2038. If this experiment is still going when it becomes significant someone will have to deal with it.

Definition at line 45 of file TTimeStamp.h.

Public Member Functions

 TTimeStamp ()
 Default ctor.
 
 TTimeStamp (const timespec_t &ts)
 
 TTimeStamp (time_t t, Int_t nsec)
 
 TTimeStamp (UInt_t date, UInt_t time, UInt_t nsec, Bool_t isUTC=kTRUE, Int_t secOffset=0)
 Create a TTimeStamp and set it to the specified date, time, nanosec.
 
 TTimeStamp (UInt_t tloc, Bool_t isUTC=kTRUE, Int_t secOffset=0, Bool_t dosDate=kFALSE)
 Create a TTimeStamp and set it to tloc which must be a time_t value returned by time().
 
 TTimeStamp (UInt_t year, UInt_t month, UInt_t day, UInt_t hour, UInt_t min, UInt_t sec, UInt_t nsec=0, Bool_t isUTC=kTRUE, Int_t secOffset=0)
 Create a TTimeStamp and set it to the specified year, month, day, time, hour, minute, second and nanosec.
 
virtual ~TTimeStamp ()
 
void Add (const TTimeStamp &offset)
 Add "offset" as a delta time.
 
Double_t AsDouble () const
 
Double_t AsGAST (Double_t UT1Offset=0) const
 Return Greenwich apparent sidereal time (GAST) in hour-angle.
 
Double_t AsGMST (Double_t UT1Offset=0) const
 Return Greenwich mean sidereal time (GMST) in hour-angle.
 
Double_t AsJulianDate () const
 
Double_t AsLAST (Double_t Longitude, Double_t UT1Offset=0) const
 Return local apparent sidereal time (LAST) in hour-angle, given a longitude in degrees.
 
Double_t AsLMST (Double_t Longitude, Double_t UT1Offset=0) const
 Return local mean sidereal time (LMST) in hour-angle, given a longitude in degrees.
 
const char * AsString (const Option_t *option="") const
 Return the date & time as a string.
 
void Copy (TTimeStamp &ts) const
 Copy this to ts.
 
UInt_t GetDate (Bool_t inUTC=kTRUE, Int_t secOffset=0, UInt_t *year=nullptr, UInt_t *month=nullptr, UInt_t *day=nullptr) const
 Return date in form of 19971224 (i.e.
 
Int_t GetDayOfWeek (Bool_t inUTC=kTRUE, Int_t secOffset=0) const
 Method is using Zeller's formula for calculating the day number.
 
Int_t GetDayOfYear (Bool_t inUTC=kTRUE, Int_t secOffset=0) const
 Get the day of the year represented by this time stamp value.
 
Int_t GetMonth (Bool_t inUTC=kTRUE, Int_t secOffset=0) const
 Get the month of the year. Valid return values are between 1 and 12.
 
Int_t GetNanoSec () const
 
time_t GetSec () const
 
UInt_t GetTime (Bool_t inUTC=kTRUE, Int_t secOffset=0, UInt_t *hour=nullptr, UInt_t *min=nullptr, UInt_t *sec=nullptr) const
 Return time in form of 123623 (i.e.
 
timespec_t GetTimeSpec () const
 
Int_t GetWeek (Bool_t inUTC=kTRUE, Int_t secOffset=0) const
 Get the week of the year.
 
virtual TClassIsA () const
 
Bool_t IsLeapYear (Bool_t inUTC=kTRUE, Int_t secOffset=0) const
 Is the year a leap year.
 
 operator double () const
 
void Print (const Option_t *option="") const
 Print date and time.
 
void Set ()
 Set Date/Time to current time as reported by the system.
 
void Set (Int_t date, Int_t time, Int_t nsec, Bool_t isUTC, Int_t secOffset)
 Set date/time from integers of the form [yy]YYMMDD and HHMMSS, assume UTC (UTC) components:
 
void Set (Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec, Int_t nsec, Bool_t isUTC, Int_t secOffset)
 Set Date/Time from components.
 
void Set (UInt_t tloc, Bool_t isUTC, Int_t secOffset, Bool_t dosDate)
 The input arg is a time_t value returned by time() or a value returned by Convert().
 
void SetNanoSec (Int_t nsec)
 
void SetSec (Int_t sec)
 
virtual void Streamer (TBuffer &)
 
void StreamerNVirtual (TBuffer &ClassDef_StreamerNVirtual_b)
 

Static Public Member Functions

static TClassClass ()
 
static const char * Class_Name ()
 
static constexpr Version_t Class_Version ()
 
static const char * DeclFileName ()
 
static void DumpTMStruct (const tm_t &tmstruct)
 Print out the "tm" structure:
 
static Int_t GetDayOfWeek (Int_t day, Int_t month, Int_t year)
 Method is using Zeller's formula for calculating the day number.
 
static Int_t GetDayOfYear (Int_t day, Int_t month, Int_t year)
 Get the day of the year represented by day, month and year.
 
static Int_t GetWeek (Int_t day, Int_t month, Int_t year)
 Get the week of the year.
 
static Int_t GetZoneOffset ()
 Static method returning local (current) time zone offset from UTC.
 
static Bool_t IsLeapYear (Int_t year)
 Is the given year a leap year.
 
static time_t MktimeFromUTC (tm_t *tmstruct)
 Equivalent of standard routine "mktime" but using the assumption that tm struct is filled with UTC, not local, time.
 

Private Member Functions

void NormalizeNanoSec ()
 Ensure that the fNanoSec field is in range [0,999999999].
 

Private Attributes

Int_t fNanoSec
 
Int_t fSec
 

Friends

Bool_t operator!= (const TTimeStamp &lhs, const TTimeStamp &rhs)
 
Bool_t operator< (const TTimeStamp &lhs, const TTimeStamp &rhs)
 
Bool_t operator<= (const TTimeStamp &lhs, const TTimeStamp &rhs)
 
Bool_t operator== (const TTimeStamp &lhs, const TTimeStamp &rhs)
 
Bool_t operator> (const TTimeStamp &lhs, const TTimeStamp &rhs)
 
Bool_t operator>= (const TTimeStamp &lhs, const TTimeStamp &rhs)
 

#include <TTimeStamp.h>

Constructor & Destructor Documentation

◆ TTimeStamp() [1/6]

TTimeStamp::TTimeStamp ( )

Default ctor.

Create a TTimeStamp and set it to the current time (as best possible). The nanosecond part is faked so that subsequent calls simply add 1 to ensure that sequential calls are distinct (and sortable).

Definition at line 95 of file TTimeStamp.cxx.

◆ TTimeStamp() [2/6]

TTimeStamp::TTimeStamp ( const timespec_t ts)
inline

Definition at line 65 of file TTimeStamp.h.

◆ TTimeStamp() [3/6]

TTimeStamp::TTimeStamp ( time_t  t,
Int_t  nsec 
)
inline

Definition at line 69 of file TTimeStamp.h.

◆ TTimeStamp() [4/6]

TTimeStamp::TTimeStamp ( UInt_t  year,
UInt_t  month,
UInt_t  day,
UInt_t  hour,
UInt_t  min,
UInt_t  sec,
UInt_t  nsec = 0,
Bool_t  isUTC = kTRUE,
Int_t  secOffset = 0 
)

Create a TTimeStamp and set it to the specified year, month, day, time, hour, minute, second and nanosec.

If !isUTC then it is assumed to be the standard local time zone.

If local time is PST then one can use

TTimeStamp(year,month,day,hour,min,sec,nsec,kFALSE,0);
constexpr Bool_t kFALSE
Definition RtypesCore.h:101
TTimeStamp()
Default ctor.

or

Int_t secOffset = 8*60*60;
TTimeStamp timeStamp(year,month,day,hour,min,sec,nsec,kTRUE,8*60*60);
constexpr Bool_t kTRUE
Definition RtypesCore.h:100
The TTimeStamp encapsulates seconds and ns since EPOCH.
Definition TTimeStamp.h:45

Definition at line 115 of file TTimeStamp.cxx.

◆ TTimeStamp() [5/6]

TTimeStamp::TTimeStamp ( UInt_t  date,
UInt_t  time,
UInt_t  nsec,
Bool_t  isUTC = kTRUE,
Int_t  secOffset = 0 
)

Create a TTimeStamp and set it to the specified date, time, nanosec.

If !isUTC then it is assumed to be the standard local time zone.

Warning
Watch out! C++ overload resolution often chooses the constructor TTimeStamp(UInt_t tloc, Bool_t isUTC, Int_t secOffset, Bool_t dosDate) instead of this one. Your best bet is to explicitly pass UInt_t values instead of Int_t values. When calling with integer literals, pass for instance
TTimeStamp timeStamp(20150610u,80448u,0u)
to disambiguate.

Definition at line 137 of file TTimeStamp.cxx.

◆ TTimeStamp() [6/6]

TTimeStamp::TTimeStamp ( UInt_t  tloc,
Bool_t  isUTC = kTRUE,
Int_t  secOffset = 0,
Bool_t  dosDate = kFALSE 
)

Create a TTimeStamp and set it to tloc which must be a time_t value returned by time().

This value is the number of seconds since the EPOCH (i.e. 00:00:00 on Jan 1m 1970). If dosDate is true then the input is a dosDate value.

Definition at line 150 of file TTimeStamp.cxx.

◆ ~TTimeStamp()

virtual TTimeStamp::~TTimeStamp ( )
inlinevirtual

Definition at line 86 of file TTimeStamp.h.

Member Function Documentation

◆ Add()

void TTimeStamp::Add ( const TTimeStamp offset)

Add "offset" as a delta time.

Definition at line 535 of file TTimeStamp.cxx.

◆ AsDouble()

Double_t TTimeStamp::AsDouble ( ) const
inline

Definition at line 112 of file TTimeStamp.h.

◆ AsGAST()

Double_t TTimeStamp::AsGAST ( Double_t  UT1Offset = 0) const

Return Greenwich apparent sidereal time (GAST) in hour-angle.

Return value will always be between 0 and 24 (hours). Sidereal time is most accurately calculated from UT1. If fSec and fNanoSec are in UTC (which they are by default), the optional argument UT1Offset can be supplied (in milliseconds). If UT1Offset is not supplied, conversion has maximum error of 1s. If offset is supplied error can be reduced to us level. Values for UT1Offset can be found in IERS Bulletin B: ftp://ftp.iers.org/products/eop/bulletinb/format_2009/ Equation of the equinoxes is given by USNO: http://aa.usno.navy.mil/faq/docs/GAST.php

Definition at line 191 of file TTimeStamp.cxx.

◆ AsGMST()

Double_t TTimeStamp::AsGMST ( Double_t  UT1Offset = 0) const

Return Greenwich mean sidereal time (GMST) in hour-angle.

Return value will always be between 0 and 24 (hours). Sidereal time is most accurately calculated from UT1. If fSec and fNanoSec are in UTC (which they are by default), the optional argument UT1Offset can be supplied (in milliseconds). If UT1Offset is not supplied, conversion has maximum error of 1s. If offset is supplied error can be reduced to us level. Values for UT1Offset can be found in IERS Bulletin B: ftp://ftp.iers.org/products/eop/bulletinb/format_2009/ The conversion to sidereal time used here is given by Aoki et. al. Astron. Astrophys. 105, 359-362 (1982) http://adsabs.harvard.edu/abs/1982A%26A...105..359A

Definition at line 168 of file TTimeStamp.cxx.

◆ AsJulianDate()

Double_t TTimeStamp::AsJulianDate ( ) const
inline

Definition at line 113 of file TTimeStamp.h.

◆ AsLAST()

Double_t TTimeStamp::AsLAST ( Double_t  Longitude,
Double_t  UT1Offset = 0 
) const

Return local apparent sidereal time (LAST) in hour-angle, given a longitude in degrees.

Return value will always be between 0 and 24 (hours). Sidereal time is most accurately calculated from UT1. If fSec and fNanoSec are in UTC (which they are by default), the optional argument UT1Offset can be supplied (in milliseconds). If UT1Offset is not supplied, conversion has maximum error of 1s. If offset is supplied error can be reduced to us level. Values for UT1Offset can be found in IERS Bulletin B: ftp://ftp.iers.org/products/eop/bulletinb/format_2009/

Definition at line 230 of file TTimeStamp.cxx.

◆ AsLMST()

Double_t TTimeStamp::AsLMST ( Double_t  Longitude,
Double_t  UT1Offset = 0 
) const

Return local mean sidereal time (LMST) in hour-angle, given a longitude in degrees.

Return value will always be between 0 and 24 (hours). Sidereal time is most accurately calculated from UT1. If fSec and fNanoSec are in UTC (which they are by default), the optional argument UT1Offset can be supplied (in milliseconds). If UT1Offset is not supplied, conversion has maximum error of 1s. If offset is supplied error can be reduced to us level. Values for UT1Offset can be found in IERS Bulletin B: ftp://ftp.iers.org/products/eop/bulletinb/format_2009/

Definition at line 214 of file TTimeStamp.cxx.

◆ AsString()

const Char_t * TTimeStamp::AsString ( const Option_t option = "") const

Return the date & time as a string.

Result is pointer to a statically allocated string. User should copy this into their own buffer before calling this method again.

Option "l" returns it in local zone format (can be applied to default or compact format).

Default format is RFC822 compliant:

"Mon, 02 Jan 2001 18:11:12 +0000 (GMT) +999999999 nsec"
"Mon, 02 Jan 2001 10:11:12 -0800 (PST) +999999999 nsec"

Option "c" compact is (almost) ISO 8601 compliant:

  • "2001-01-02 18:11:12.9999999999Z"
  • "2001-01-02 10:11:12.9999999999-0800" if PST

    • uses "-" as date separator as specified in ISO 8601
    • uses "." rather than preferred "," for decimal separator
    • -HHMM is the difference between local and UTC (if behind, + if ahead).

    The "-HHMM" is replaced with "Z" if given as UTC. To be strictly conforming it should use "T" instead of the blank separating the date and time.

Option "2" returns as {sec,nsec} integers.

Option "s" returns "2001-01-02 18:11:12" with an implied UTC, overrides "l" option.

Internally uses a circular list of buffers to avoid problems using AsString multiple times in a single statement.

Definition at line 271 of file TTimeStamp.cxx.

◆ Class()

static TClass * TTimeStamp::Class ( )
static
Returns
TClass describing this class

◆ Class_Name()

static const char * TTimeStamp::Class_Name ( )
static
Returns
Name of this class

◆ Class_Version()

static constexpr Version_t TTimeStamp::Class_Version ( )
inlinestaticconstexpr
Returns
Version of this class

Definition at line 151 of file TTimeStamp.h.

◆ Copy()

void TTimeStamp::Copy ( TTimeStamp ts) const

Copy this to ts.

Definition at line 344 of file TTimeStamp.cxx.

◆ DeclFileName()

static const char * TTimeStamp::DeclFileName ( )
inlinestatic
Returns
Name of the file containing the class declaration

Definition at line 151 of file TTimeStamp.h.

◆ DumpTMStruct()

void TTimeStamp::DumpTMStruct ( const tm_t tmstruct)
static

Print out the "tm" structure:

tmstruct.tm_year = year; // years since 1900
tmstruct.tm_mon = month-1; // months since Jan [0,11]
tmstruct.tm_mday = day; // day of the month [1,31]
tmstruct.tm_hour = hour; // hours since midnight [0,23]
tmstruct.tm_min = min; // minutes after the hour [0,59]
tmstruct.tm_sec = sec; // seconds after the minute [0,59]
tmstruct.tm_wday // day of week [0,6]
tmstruct.tm_yday // days in year [0,365]
tmstruct.tm_isdst // DST [-1/0/1] (unknown,false,true)

Definition at line 904 of file TTimeStamp.cxx.

◆ GetDate()

UInt_t TTimeStamp::GetDate ( Bool_t  inUTC = kTRUE,
Int_t  secOffset = 0,
UInt_t year = nullptr,
UInt_t month = nullptr,
UInt_t day = nullptr 
) const

Return date in form of 19971224 (i.e.

24/12/1997), if non-zero pointers supplied for year, month, day fill those as well.

Definition at line 354 of file TTimeStamp.cxx.

◆ GetDayOfWeek() [1/2]

Int_t TTimeStamp::GetDayOfWeek ( Bool_t  inUTC = kTRUE,
Int_t  secOffset = 0 
) const

Method is using Zeller's formula for calculating the day number.

Valid return values range between 1 and 7, where Monday = 1.

Definition at line 419 of file TTimeStamp.cxx.

◆ GetDayOfWeek() [2/2]

Int_t TTimeStamp::GetDayOfWeek ( Int_t  day,
Int_t  month,
Int_t  year 
)
static

Method is using Zeller's formula for calculating the day number.

Valid return values range between 1 and 7, where Monday = 1.

Definition at line 830 of file TTimeStamp.cxx.

◆ GetDayOfYear() [1/2]

Int_t TTimeStamp::GetDayOfYear ( Bool_t  inUTC = kTRUE,
Int_t  secOffset = 0 
) const

Get the day of the year represented by this time stamp value.

Valid return values range between 1 and 366, where January 1 = 1.

Definition at line 398 of file TTimeStamp.cxx.

◆ GetDayOfYear() [2/2]

Int_t TTimeStamp::GetDayOfYear ( Int_t  day,
Int_t  month,
Int_t  year 
)
static

Get the day of the year represented by day, month and year.

Valid return values range between 1 and 366, where January 1 = 1.

Definition at line 813 of file TTimeStamp.cxx.

◆ GetMonth()

Int_t TTimeStamp::GetMonth ( Bool_t  inUTC = kTRUE,
Int_t  secOffset = 0 
) const

Get the month of the year. Valid return values are between 1 and 12.

Definition at line 439 of file TTimeStamp.cxx.

◆ GetNanoSec()

Int_t TTimeStamp::GetNanoSec ( ) const
inline

Definition at line 110 of file TTimeStamp.h.

◆ GetSec()

time_t TTimeStamp::GetSec ( ) const
inline

Definition at line 109 of file TTimeStamp.h.

◆ GetTime()

UInt_t TTimeStamp::GetTime ( Bool_t  inUTC = kTRUE,
Int_t  secOffset = 0,
UInt_t hour = nullptr,
UInt_t min = nullptr,
UInt_t sec = nullptr 
) const

Return time in form of 123623 (i.e.

12:36:23), if non-zero pointers supplied for hour, min, sec fill those as well.

Definition at line 376 of file TTimeStamp.cxx.

◆ GetTimeSpec()

timespec_t TTimeStamp::GetTimeSpec ( ) const
inline

Definition at line 107 of file TTimeStamp.h.

◆ GetWeek() [1/2]

Int_t TTimeStamp::GetWeek ( Bool_t  inUTC = kTRUE,
Int_t  secOffset = 0 
) const

Get the week of the year.

Valid week values are between 1 and 53. The return value is the year*100+week (1 Jan may be in the last week of the previous year so the year must be returned too).

Definition at line 457 of file TTimeStamp.cxx.

◆ GetWeek() [2/2]

Int_t TTimeStamp::GetWeek ( Int_t  day,
Int_t  month,
Int_t  year 
)
static

Get the week of the year.

Valid week values are between 1 and 53. The return value is the year*100+week (1 Jan may be in the last week of the previous year so the year must be returned too).

Definition at line 851 of file TTimeStamp.cxx.

◆ GetZoneOffset()

Int_t TTimeStamp::GetZoneOffset ( )
static

Static method returning local (current) time zone offset from UTC.

This is the value in seconds one must add to the local time to arrive at Coordinated Universal Time, so it is negative east of the Prime Meridian.

Definition at line 505 of file TTimeStamp.cxx.

◆ IsA()

virtual TClass * TTimeStamp::IsA ( ) const
inlinevirtual
Returns
TClass describing current object

Definition at line 151 of file TTimeStamp.h.

◆ IsLeapYear() [1/2]

Bool_t TTimeStamp::IsLeapYear ( Bool_t  inUTC = kTRUE,
Int_t  secOffset = 0 
) const

Is the year a leap year.

The calendar year is 365 days long, unless the year is exactly divisible by 4, in which case an extra day is added to February to make the year 366 days long. If the year is the last year of a century, eg. 1700, 1800, 1900, 2000, then it is only a leap year if it is exactly divisible by

  1. Therefore, 1900 wasn't a leap year but 2000 was. The reason for these rules is to bring the average length of the calendar year into line with the length of the Earth's orbit around the Sun, so that the seasons always occur during the same months each year.

Definition at line 485 of file TTimeStamp.cxx.

◆ IsLeapYear() [2/2]

Bool_t TTimeStamp::IsLeapYear ( Int_t  year)
static

Is the given year a leap year.

The calendar year is 365 days long, unless the year is exactly divisible by 4, in which case an extra day is added to February to make the year 366 days long. If the year is the last year of a century, eg. 1700, 1800, 1900, 2000, then it is only a leap year if it is exactly divisible by

  1. Therefore, 1900 wasn't a leap year but 2000 was. The reason for these rules is to bring the average length of the calendar year into line with the length of the Earth's orbit around the Sun, so that the seasons always occur during the same months each year.

Definition at line 885 of file TTimeStamp.cxx.

◆ MktimeFromUTC()

time_t TTimeStamp::MktimeFromUTC ( tm_t tmstruct)
static

Equivalent of standard routine "mktime" but using the assumption that tm struct is filled with UTC, not local, time.

This version ISN'T configured to handle every possible weirdness of out-of-range values in the case of normalizing the tm struct.

This version DOESN'T correctly handle values that can't be fit into a time_t (i.e. beyond year 2038-01-18 19:14:07, or before the start of Epoch).

Definition at line 768 of file TTimeStamp.cxx.

◆ NormalizeNanoSec()

void TTimeStamp::NormalizeNanoSec ( )
private

Ensure that the fNanoSec field is in range [0,999999999].

Definition at line 740 of file TTimeStamp.cxx.

◆ operator double()

TTimeStamp::operator double ( ) const
inline

Definition at line 140 of file TTimeStamp.h.

◆ Print()

void TTimeStamp::Print ( const Option_t option = "") const

Print date and time.

Definition at line 545 of file TTimeStamp.cxx.

◆ Set() [1/4]

void TTimeStamp::Set ( )

Set Date/Time to current time as reported by the system.

No accounting for nanoseconds with std ANSI functions, ns part faked so that subsequent calls simply add 1 to it this ensures that calls within the same second come back distinct (and sortable). Time is since Jan 1, 1970.

Definition at line 557 of file TTimeStamp.cxx.

◆ Set() [2/4]

void TTimeStamp::Set ( Int_t  date,
Int_t  time,
Int_t  nsec,
Bool_t  isUTC,
Int_t  secOffset 
)

Set date/time from integers of the form [yy]YYMMDD and HHMMSS, assume UTC (UTC) components:

MM: 01=January .. 12=December
DD: 01 .. 31
HH: 00=midnight .. 23
MM: 00 .. 59
SS: 00 .. 69
  • Date must be in format 980418 or 19980418 1001127 or 20001127 (i.e. year 100 = 2000),
  • time must be in format 224512 (second precision),
  • date must be >= 700101.

Definition at line 661 of file TTimeStamp.cxx.

◆ Set() [3/4]

void TTimeStamp::Set ( Int_t  year,
Int_t  month,
Int_t  day,
Int_t  hour,
Int_t  min,
Int_t  sec,
Int_t  nsec,
Bool_t  isUTC,
Int_t  secOffset 
)

Set Date/Time from components.

Month & day both use normal 1..12 and 1..31 counting, hours, min, sec run from 0 to 23, 59, 59 respectively, secOffset provides method for adjusting for alternative timezones

"year" | 0 1 ... 37 | 38...69 | 70 .. 100 101 .. 137
true | 2000 2001 2037 | undefined | 1970 2000 2001 .. 2037
"year" | 138...1969 | 1970 .. 2037 | ...
true | undefined | 1970 .. 2037 | undefined

Definition at line 608 of file TTimeStamp.cxx.

◆ Set() [4/4]

void TTimeStamp::Set ( UInt_t  tloc,
Bool_t  isUTC,
Int_t  secOffset,
Bool_t  dosDate 
)

The input arg is a time_t value returned by time() or a value returned by Convert().

This value is the number of seconds since the EPOCH (i.e. 00:00:00 on Jan 1m 1970). If dosDate is true then the input is a dosDate value.

Definition at line 691 of file TTimeStamp.cxx.

◆ SetNanoSec()

void TTimeStamp::SetNanoSec ( Int_t  nsec)
inline

Definition at line 105 of file TTimeStamp.h.

◆ SetSec()

void TTimeStamp::SetSec ( Int_t  sec)
inline

Definition at line 104 of file TTimeStamp.h.

◆ Streamer()

virtual void TTimeStamp::Streamer ( TBuffer )
virtual

◆ StreamerNVirtual()

void TTimeStamp::StreamerNVirtual ( TBuffer ClassDef_StreamerNVirtual_b)
inline

Definition at line 151 of file TTimeStamp.h.

Friends And Related Symbol Documentation

◆ operator!=

Bool_t operator!= ( const TTimeStamp lhs,
const TTimeStamp rhs 
)
friend

Definition at line 159 of file TTimeStamp.h.

◆ operator<

Bool_t operator< ( const TTimeStamp lhs,
const TTimeStamp rhs 
)
friend

Definition at line 163 of file TTimeStamp.h.

◆ operator<=

Bool_t operator<= ( const TTimeStamp lhs,
const TTimeStamp rhs 
)
friend

Definition at line 168 of file TTimeStamp.h.

◆ operator==

Bool_t operator== ( const TTimeStamp lhs,
const TTimeStamp rhs 
)
friend

Definition at line 155 of file TTimeStamp.h.

◆ operator>

Bool_t operator> ( const TTimeStamp lhs,
const TTimeStamp rhs 
)
friend

Definition at line 173 of file TTimeStamp.h.

◆ operator>=

Bool_t operator>= ( const TTimeStamp lhs,
const TTimeStamp rhs 
)
friend

Definition at line 178 of file TTimeStamp.h.

Member Data Documentation

◆ fNanoSec

Int_t TTimeStamp::fNanoSec
private

Definition at line 56 of file TTimeStamp.h.

◆ fSec

Int_t TTimeStamp::fSec
private

Definition at line 55 of file TTimeStamp.h.

  • core/base/inc/TTimeStamp.h
  • core/base/src/TTimeStamp.cxx