Statistics
| Branch: | Tag: | Revision:

sssimulator / EventScheduler / action_event_struct.h @ master

History | View | Annotate | Download (551 Bytes)

1 af271552 luca
/*
2
 * this is sssim: the simple & stupid simulator
3
 *
4
 *  copyright (c) 2015 luca baldesi
5
 *
6
 *  this is free software; see gpl-3.0.txt
7
 */
8
9
#ifndef __ACTION_EVENT_STRUCT_H__
10
#define __ACTION_EVENT_STRUCT_H__ 1
11
12
#include"action_event.h"
13 0bf1a874 Luca Baldesi
#include <inttypes.h>
14 af271552 luca
15
struct action_event {
16
        double time;
17 0bf1a874 Luca Baldesi
        uint8_t priority;  // to be used when scheduling events with same time
18 af271552 luca
        action_event_func_t trigger;
19
        action_event_destroy_func_t destroy;
20
};
21
22 bf3d3ebd Luca Baldesi
void action_event_init(struct action_event *ae, action_event_func_t t, action_event_destroy_func_t d);
23 af271552 luca
24
#endif