]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/msm/doc/HTML/examples/distributed_table/Empty.hpp
bump version to 12.2.2-pve1
[ceph.git] / ceph / src / boost / libs / msm / doc / HTML / examples / distributed_table / Empty.hpp
1 // Copyright 2010 Christophe Henry
2 // henry UNDERSCORE christophe AT hotmail DOT com
3 // This is an extended version of the state machine available in the boost::mpl library
4 // Distributed under the same license as the original.
5 // Copyright for the original version:
6 // Copyright 2005 David Abrahams and Aleksey Gurtovoy. Distributed
7 // under the Boost Software License, Version 1.0. (See accompanying
8 // file LICENSE_1_0.txt or copy at
9 // http://www.boost.org/LICENSE_1_0.txt)
10
11 #ifndef EMPTY_HPP
12 #define EMPTY_HPP
13
14 // back-end
15 #include <boost/msm/back/state_machine.hpp>
16 //front-end
17 #include <boost/msm/front/state_machine_def.hpp>
18 #include <boost/msm/front/row2.hpp>
19
20 #include "Events.hpp"
21
22 struct Open;
23
24 namespace msm = boost::msm;
25 namespace mpl = boost::mpl;
26
27 struct Empty : public msm::front::state<>
28 {
29 template <class Event,class FSM>
30 void on_entry(Event const&,FSM& ) {std::cout << "entering: Empty" << std::endl;}
31 template <class Event,class FSM>
32 void on_exit(Event const&,FSM& ) {std::cout << "leaving: Empty" << std::endl;}
33 void open_drawer(open_close const&);
34
35 struct internal_transition_table : mpl::vector<
36 // Start Event Next Action Guard
37 //+-------------+---------+-------------+---------+---------------------------+----------------------+
38 msm::front::a_row2 < Empty , open_close , Open , Empty,&Empty::open_drawer >
39 //+-------------+---------+-------------+---------+---------------------------+----------------------+
40 > {};
41 };
42
43 #endif