implement event class

This commit is contained in:
Joel Beckmeyer 2017-04-10 17:15:05 -04:00
parent 0abbc7440e
commit bc949ffea7
5 changed files with 18 additions and 16 deletions

View File

@ -2,5 +2,4 @@
# TODO # TODO
* implement vector file parsing * implement vector file parsing
* develop pQueue class
* define all classes more completely * define all classes more completely

View File

@ -0,0 +1,13 @@
#include "event.h"
using namespace std;
event::event(event, value, setTime, wire) : evNum(event), evValue(value),
evTime(setTime), wireNum(wire) {}
bool event::operator<(const event &e1, const event &e2) {
if(e1.evTime == e2.evTime) {
return e1.evNum > e2.evNum;
}
return e1.evTime > e2.evTime;
}

View File

@ -2,12 +2,11 @@
#define EVENT #define EVENT
class event { class event {
/* TODO: public:
* event number event(event, value, setTime, wire);
* value bool operator<(const event &e1, const event &e2);
* time private:
* wire number int evNum, evValue, evTime, wireNum;
*/
}; };
#endif // !EVENT #endif // !EVENT

View File

@ -1 +0,0 @@
#include "pQueue.h"

View File

@ -1,8 +0,0 @@
#ifndef pQUEUE
#define pQUEUE
class pQueue {
//TODO
};
#endif // !pQUEUE