16#ifndef SIMICS_EVENT_INTERFACE_H
17#define SIMICS_EVENT_INTERFACE_H
19#include <simics/base/event.h>
20#include <simics/base/time.h>
51 virtual void remove(
void *match_data)
const = 0;
53 virtual bool posted(
void *match_data)
const = 0;
56 virtual double next(
void *data)
const = 0;
58 virtual void post(
double seconds,
void *data) = 0;
65 virtual void remove(
void *match_data)
const = 0;
67 virtual bool posted(
void *match_data)
const = 0;
70 virtual cycles_t
next(
void *match_data)
const = 0;
72 virtual void post(cycles_t cycles,
void *data) = 0;
79 virtual void remove(
void *match_data)
const = 0;
81 virtual bool posted(
void *match_data)
const = 0;
84 virtual pc_step_t
next(
void *match_data)
const = 0;
86 virtual void post(pc_step_t steps,
void *data) = 0;
Definition: event-interface.h:61
virtual void remove(void *match_data) const =0
Removes all events of this type with matching data from the queue.
virtual bool posted(void *match_data) const =0
Returns true if the event is in the queue, and false otherwise.
virtual cycles_t next(void *match_data) const =0
Returns the cycles to the next occurrence of the event in the queue (relative to the current time)
virtual ~CycleEventInterface()=default
virtual void post(cycles_t cycles, void *data)=0
Posts the event on the associated queue of the device.
An event is required to implement the interface.
Definition: event-interface.h:29
virtual void * set_value(attr_value_t value)=0
Called to convert a configuration value into event data.
virtual void destroy(void *data)=0
Called when the event is removed from the queue without being called.
virtual ~EventInterface()=default
virtual attr_value_t get_value(void *data)=0
Called to convert the event data into a value that can be saved in a configuration.
virtual void callback(void *data)=0
Called when the event expires.
virtual char * describe(void *data) const =0
Called to generate a human-readable description of the event to be used in the print-event-queue comm...
Definition: event-interface.h:75
virtual pc_step_t next(void *match_data) const =0
Returns the steps to the next occurrence of the event in the queue (relative to the current time)
virtual bool posted(void *match_data) const =0
Returns true if the event is in the queue, and false otherwise.
virtual void remove(void *match_data) const =0
Removes all events of this type with matching data from the queue.
virtual ~StepEventInterface()=default
virtual void post(pc_step_t steps, void *data)=0
Posts the event on the associated queue of the device.
Definition: event-interface.h:47
virtual void post(double seconds, void *data)=0
Posts the event on the associated queue of the device.
virtual double next(void *data) const =0
Returns the time to the next occurrence of the event in the queue (relative to the current time)
virtual void remove(void *match_data) const =0
Removes all events of this type with matching data from the queue.
virtual bool posted(void *match_data) const =0
Returns true if the event is in the queue, and false otherwise.
virtual ~TimeEventInterface()=default
Definition: after-bank.h:33