10 #ifndef __PION_TCP_TIMER_HEADER__
11 #define __PION_TCP_TIMER_HEADER__
13 #include <boost/asio.hpp>
14 #include <boost/bind.hpp>
15 #include <boost/shared_ptr.hpp>
16 #include <boost/enable_shared_from_this.hpp>
17 #include <boost/thread/mutex.hpp>
18 #include <pion/config.hpp>
19 #include <pion/tcp/connection.hpp>
30 :
public boost::enable_shared_from_this<timer>
39 timer(tcp::connection_ptr& conn_ptr);
46 void start(
const boost::uint32_t seconds);
59 void timer_callback(
const boost::system::error_code& ec);
62 tcp::connection_ptr m_conn_ptr;
65 boost::asio::deadline_timer m_timer;
79 typedef boost::shared_ptr<timer> timer_ptr;