-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathcallback.h
50 lines (40 loc) · 945 Bytes
/
callback.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#ifndef CALLBACK_H
#define CALLBACK_H
#include <string>
#include <map>
using namespace std;
class trigger
{
public:
trigger(string, string, string);
string getName();
string getPattern();
string getCommand();
private:
string name;
string pattern;
string command;
};
class callback
{
public:
callback(string, string, string, long = 0, long = 0);
void setPosition(long);
void setSize(long);
string getFile();
string getName();
string getLogfile();
long getPosition();
long getSize();
void addTrigger(string, string, string);
map<string, trigger> getTriggers();
int getTriggersCount();
private:
string file;
string name;
string logfile;
long position;
long size;
map<string, trigger> triggers;
};
#endif // CALLBACK_H