]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/mpl/example/fsm/aux_/event.hpp
add subtree-ish sources for 12.0.3
[ceph.git] / ceph / src / boost / libs / mpl / example / fsm / aux_ / event.hpp
1
2 #ifndef BOOST_FSM_EVENT_INCLUDED
3 #define BOOST_FSM_EVENT_INCLUDED
4
5 // Copyright Aleksey Gurtovoy 2002-2004
6 //
7 // Distributed under the Boost Software License, Version 1.0.
8 // (See accompanying file LICENSE_1_0.txt or copy at
9 // http://www.boost.org/LICENSE_1_0.txt)
10 //
11 // See http://www.boost.org/libs/mpl for documentation.
12
13 // $Id$
14 // $Date$
15 // $Revision$
16
17 #include "base_event.hpp"
18
19 namespace fsm { namespace aux {
20
21 template< typename Derived >
22 struct event
23 : base_event
24 {
25 public:
26 typedef base_event base_t;
27
28 private:
29 virtual std::auto_ptr<base_event> do_clone() const
30 {
31 return std::auto_ptr<base_event>(
32 new Derived(static_cast<Derived const&>(*this))
33 );
34 }
35 };
36
37 }}
38
39 #endif // BOOST_FSM_EVENT_INCLUDED