2014-11-19 00:25:21 +08:00
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
class host_status;
|
|
|
|
|
class ping_callback;
|
|
|
|
|
class ping_store : public acl::rpc_request
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
ping_store(std::vector<host_status*>* host_list,
|
|
|
|
|
ping_callback* callback);
|
|
|
|
|
~ping_store();
|
|
|
|
|
protected:
|
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD>麯<EFBFBD><E9BAAF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̴߳<DFB3><CCB4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
virtual void rpc_run();
|
|
|
|
|
|
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD>麯<EFBFBD><E9BAAF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̴߳<DFB3><CCB4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̣<EFBFBD><CCA3>յ<EFBFBD><D5B5><EFBFBD><EFBFBD>߳<EFBFBD><DFB3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɵ<EFBFBD><C9B5><EFBFBD>Ϣ
|
|
|
|
|
virtual void rpc_onover();
|
|
|
|
|
private:
|
|
|
|
|
std::vector<host_status*>* host_list_;
|
|
|
|
|
|
|
|
|
|
acl::string dbpath_;
|
|
|
|
|
ping_callback* callback_;
|
|
|
|
|
bool create_tbl(acl::db_handle& db);
|
|
|
|
|
void insert_tbl(acl::db_handle& db);
|
|
|
|
|
void insert_one(acl::db_handle& db, const host_status* status);
|
2013-08-18 17:42:25 +08:00
|
|
|
|
};
|