Public Member Functions | Public Attributes | Friends | List of all members
genie::NtpMCDTime Class Reference

MINOS-style Ntuple Class to hold the date and time that the event ntuple was generated. More...

#include <NtpMCDTime.h>

Inheritance diagram for genie::NtpMCDTime:

Public Member Functions

 NtpMCDTime ()
 
 NtpMCDTime (const NtpMCDTime &dt)
 
virtual ~NtpMCDTime ()
 
void Now (void)
 
void Init (void)
 
void Copy (const NtpMCDTime &dt)
 
void PrintToStream (ostream &stream) const
 

Public Attributes

Int_t year
 
Int_t month
 
Int_t day
 
Int_t hour
 
Int_t min
 
Int_t sec
 
UInt_t val
 sec since 1st Jan 1995 as in TDatime More...
 

Friends

ostream & operator<< (ostream &stream, const NtpMCDTime &dt)
 

Detailed Description

MINOS-style Ntuple Class to hold the date and time that the event ntuple was generated.

Author
Costas Andreopoulos <constantinos.andreopoulos cern.ch> University of Liverpool & STFC Rutherford Appleton Laboratory

October 18, 2004

Copyright (c) 2003-2020, The GENIE Collaboration For the full text of the license visit http://copyright.genie-mc.org

Definition at line 33 of file NtpMCDTime.h.

Constructor & Destructor Documentation

NtpMCDTime::NtpMCDTime ( )

Definition at line 30 of file NtpMCDTime.cxx.

30  :
31 TObject()
32 {
33  this->Init();
34 }
void Init(void)
Definition: NtpMCDTime.cxx:65
NtpMCDTime::NtpMCDTime ( const NtpMCDTime dt)

Definition at line 36 of file NtpMCDTime.cxx.

36  :
37 TObject()
38 {
39  this->Copy(dt);
40 }
void Copy(const NtpMCDTime &dt)
Definition: NtpMCDTime.cxx:54
NtpMCDTime::~NtpMCDTime ( )
virtual

Definition at line 42 of file NtpMCDTime.cxx.

43 {
44 
45 }

Member Function Documentation

void NtpMCDTime::Copy ( const NtpMCDTime dt)

Definition at line 54 of file NtpMCDTime.cxx.

55 {
56  year = dt.year;
57  month = dt.month;
58  day = dt.day;
59  hour = dt.hour;
60  min = dt.min;
61  sec = dt.sec;
62  val = dt.val;
63 }
UInt_t val
sec since 1st Jan 1995 as in TDatime
Definition: NtpMCDTime.h:58
void NtpMCDTime::Init ( void  )

Definition at line 65 of file NtpMCDTime.cxx.

66 {
67  year = 0;
68  month = 0;
69  day = 0;
70  hour = 0;
71  min = 0;
72  sec = 0;
73  val = 0;
74 }
void NtpMCDTime::Now ( void  )

Definition at line 76 of file NtpMCDTime.cxx.

77 {
78  TDatime t;
79 
80  year = t.GetYear();
81  month = t.GetMonth();
82  day = t.GetDay();
83  hour = t.GetHour();
84  min = t.GetMinute();
85  sec = t.GetSecond();
86  val = t.Get();
87 }
void NtpMCDTime::PrintToStream ( ostream &  stream) const

Definition at line 47 of file NtpMCDTime.cxx.

48 {
49  stream
50  << "DATE (dd/mm/yyyy): " << day << "/" << month << "/" << year
51  << ", TIME (hr:min:sec): " << hour << ":" << min << ":" << sec << endl;
52 }
QTextStream & endl(QTextStream &s)

Friends And Related Function Documentation

ostream& operator<< ( ostream &  stream,
const NtpMCDTime dt 
)
friend

Definition at line 23 of file NtpMCDTime.cxx.

24  {
26  return stream;
27  }
void PrintToStream(ostream &stream) const
Definition: NtpMCDTime.cxx:47

Member Data Documentation

Int_t genie::NtpMCDTime::day

Definition at line 54 of file NtpMCDTime.h.

Int_t genie::NtpMCDTime::hour

Definition at line 55 of file NtpMCDTime.h.

Int_t genie::NtpMCDTime::min

Definition at line 56 of file NtpMCDTime.h.

Int_t genie::NtpMCDTime::month

Definition at line 53 of file NtpMCDTime.h.

Int_t genie::NtpMCDTime::sec

Definition at line 57 of file NtpMCDTime.h.

UInt_t genie::NtpMCDTime::val

sec since 1st Jan 1995 as in TDatime

Definition at line 58 of file NtpMCDTime.h.

Int_t genie::NtpMCDTime::year

Definition at line 52 of file NtpMCDTime.h.


The documentation for this class was generated from the following files: