21 #ifndef BM_BM_SIM_ACTION_ENTRY_H_
22 #define BM_BM_SIM_ACTION_ENTRY_H_
28 #include "control_flow.h"
35 ActionEntry(ActionFnEntry action_fn,
const ControlFlowNode *next_node)
36 : action_fn(std::move(action_fn)), next_node(next_node) { }
38 void dump(std::ostream *stream)
const {
39 action_fn.dump(stream);
42 void serialize(std::ostream *out)
const;
43 void deserialize(std::istream *in,
const P4Objects &objs);
45 friend std::ostream& operator<<(std::ostream &out,
const ActionEntry &e) {
50 ActionEntry(
const ActionEntry &other) =
default;
51 ActionEntry &operator=(
const ActionEntry &other) =
default;
53 ActionEntry(ActionEntry &&other) =
default;
54 ActionEntry &operator=(ActionEntry &&other) =
default;
56 ActionFnEntry action_fn{};
57 const ControlFlowNode *next_node{
nullptr};
62 #endif // BM_BM_SIM_ACTION_ENTRY_H_