1 #ifndef SAKI_APP_SERVER_H 2 #define SAKI_APP_SERVER_H 5 #include "../table/table.h" 17 using Msgs = std::vector<TableMsg>;
19 explicit TableServer(Table::InitConfig config, std::vector<TableObserver *> obs,
23 Msgs action(
Who who,
const Action &action,
int nonce);
30 void onTableEvent(
const Table &table,
const TE::Diced &event)
final;
31 void onTableEvent(
const Table &table,
const TE::Dealt &event)
final;
33 void onTableEvent(
const Table &table,
const TE::Drawn &event)
final;
43 const Table &table()
const;
46 void pushActivationMsgs();
47 void pushActivationMsg(
Who who,
bool isResume =
false);
48 void pushPointsChanged(
const Table &table);
49 void pushActionExpired(
Who who);
50 void pushActionIllegal(
Who who);
53 void pushBroadcastMsg(
const char *event,
const nlohmann::json &args);
64 std::array<int, 4> mNonces;
73 #endif // SAKI_APP_TABLE_SERVER_H Definition: table_event.h:60
Definition: table_event.h:82
Definition: table_observer.h:38
Definition: table_event.h:77
Definition: table_event.h:131
Definition: table_event.h:140
Definition: table_event.h:94
Definition: table_event.h:145
Definition: table_env.h:11
Definition: table_event.h:66
Definition: table_event.h:105
Definition: table_event.h:99
Definition: table_view.h:18
Definition: table_event.h:89
Definition: table_event.h:123
Definition: table_event.h:117
Definition: table_event.h:152
Definition: table_server.h:14
Definition: table_event.h:54
Definition: table_event.h:111