This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifndef __DISPATCHER_H | |
#define __DISPATCHER_H | |
#include <functional> | |
#include <list> | |
template <typename... Args> | |
class Dispatcher | |
{ | |
public: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <string> | |
#include "dispatcher.hpp" // the implementation is here | |
using namespace std; | |
// a dummy enum for this example | |
enum EventEnum {EVENT1, EVENT2, EVENT3}; | |
int main(int argc, char *argv[]) |