Jpp  master_rocky
the software that should make you happy
Public Member Functions | Public Attributes | Friends | List of all members
JFIT::JEvent Struct Reference

Auxiliary class for historical event. More...

#include <JHistory.hh>

Public Member Functions

 JEvent ()
 Default constructor. More...
 
 JEvent (const int type)
 Constructor. More...
 
virtual ~JEvent ()
 Virtual destructor. More...
 
 ClassDef (JEvent, 2)
 

Public Attributes

int type
 application type More...
 
JUUID uuid
 UUID. More...
 
std::string git
 GIT revision. More...
 
std::string date
 date More...
 

Friends

std::ostream & operator<< (std::ostream &out, const JEvent &event)
 Write event to output stream. More...
 

Detailed Description

Auxiliary class for historical event.

Definition at line 36 of file JHistory.hh.

Constructor & Destructor Documentation

◆ JEvent() [1/2]

JFIT::JEvent::JEvent ( )
inline

Default constructor.

Definition at line 40 of file JHistory.hh.

40  :
41  type(-1),
42  uuid()
43  {}
int type
application type
Definition: JHistory.hh:89
JUUID uuid
UUID.
Definition: JHistory.hh:90

◆ JEvent() [2/2]

JFIT::JEvent::JEvent ( const int  type)
inline

Constructor.

Parameters
typeapplication type

Definition at line 50 of file JHistory.hh.

51  {
52  using namespace JPP;
53 
54  this->type = type;
55  this->uuid = JUUID::rndm();
56  this->git = getGITVersion();
57  this->date = getDateAndTime();
58  }
std::string getGITVersion(const std::string &tag)
Get GIT version for given GIT tag.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
static JDateAndTime getDateAndTime
Function object to get current date and time.
std::string date
date
Definition: JHistory.hh:92
std::string git
GIT revision.
Definition: JHistory.hh:91
static const JUUID & rndm()
Generate random UUID.
Definition: JUUID.hh:78

◆ ~JEvent()

virtual JFIT::JEvent::~JEvent ( )
inlinevirtual

Virtual destructor.

Definition at line 64 of file JHistory.hh.

65  {}

Member Function Documentation

◆ ClassDef()

JFIT::JEvent::ClassDef ( JEvent  ,
 
)

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  out,
const JEvent event 
)
friend

Write event to output stream.

Parameters
outoutput stream
eventevent
Returns
output stream

Definition at line 75 of file JHistory.hh.

76  {
77  using namespace std;
78 
79  out << setw(3) << right << event.type << ' '
80  << setw(36) << left << event.uuid << ' '
81  << setw(20) << left << event.git << ' '
82  << setw(20) << left << event.date << right;
83 
84  return out;
85  }
Definition: JSTDTypes.hh:14

Member Data Documentation

◆ type

int JFIT::JEvent::type

application type

Definition at line 89 of file JHistory.hh.

◆ uuid

JUUID JFIT::JEvent::uuid

UUID.

Definition at line 90 of file JHistory.hh.

◆ git

std::string JFIT::JEvent::git

GIT revision.

Definition at line 91 of file JHistory.hh.

◆ date

std::string JFIT::JEvent::date

date

Definition at line 92 of file JHistory.hh.


The documentation for this struct was generated from the following file: