Changeset 14563 for trunk/FACT++
- Timestamp:
- 11/05/12 18:41:09 (12 years ago)
- Location:
- trunk/FACT++/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/Event.cc
r14003 r14563 43 43 // 44 44 Event::Event(const string &name, const string &fmt) : 45 fName(name), fFormat(fmt), fTime(Time::none), fQoS(0) 45 fName(name), fFormat(fmt), fTime(Time::none), fQoS(0), fEmpty(true) 46 46 { 47 47 } … … 59 59 fName(evt.GetName()), fFormat(evt.GetFormat()), 60 60 fData(evt.GetText(), evt.GetText()+evt.GetSize()), fTime(evt.GetTime()), 61 fQoS(evt.GetQoS()) 61 fQoS(evt.GetQoS()), fEmpty(evt.IsEmpty()) 62 62 { 63 63 const size_t pos = fName.find_first_of('/'); … … 83 83 Event::Event(const EventImp &evt, const char *ptr, size_t siz) : EventImp(evt), 84 84 fName(evt.GetName()), fFormat(evt.GetFormat()), 85 fData(ptr, ptr+siz), fTime(evt.GetTime()), fQoS(evt.GetQoS()) 85 fData(ptr, ptr+siz), fTime(evt.GetTime()), fQoS(evt.GetQoS()), fEmpty(ptr==0) 86 86 { 87 87 const size_t pos = fName.find_first_of('/'); -
trunk/FACT++/src/Event.h
r14094 r14563 15 15 Time fTime; /// Time stamp 16 16 int fQoS; /// Quality of service 17 bool fEmpty; /// Empty is true if received event was a NULL pointer 17 18 18 19 public: 19 Event() { }20 Event() : fQoS(0), fEmpty(true) { } 20 21 /// Constructs an event as a combination of an EventImp and a DimCommand 21 22 Event(const std::string &name, const std::string &fmt=""); … … 39 40 /// Return reference to a time stamp 40 41 Time GetTime() const { return fTime; } 42 /// Return Quality of Service 41 43 int GetQoS() const { return fQoS; } 42 44 /// Return if event is not just zero size but empty 45 bool IsEmpty() const { return fEmpty; } 43 46 44 47 void SetTime() { fTime = Time(); }
Note:
See TracChangeset
for help on using the changeset viewer.