ExpireTimer.h

Go to the documentation of this file.
00001 
00022 #ifndef HYPERTABLE_EXPIRE_TIMER_H
00023 #define HYPERTABLE_EXPIRE_TIMER_H
00024 
00025 #include <boost/thread/xtime.hpp>
00026 
00027 #include "DispatchHandler.h"
00028 
00029 namespace Hypertable {
00030 
00031   struct ExpireTimer {
00032     boost::xtime       expire_time;
00033     DispatchHandlerPtr handler;
00034   };
00035 
00036   struct LtTimer {
00037     bool operator()(const ExpireTimer &t1, const ExpireTimer &t2) const {
00038       return xtime_cmp(t1.expire_time, t2.expire_time) > 0;
00039     }
00040   };
00041 
00042 }
00043 
00044 #endif // HYPERTABLE_ExpireTimer_H