1
This commit is contained in:
parent
f55a658d77
commit
0f27c9f860
@ -25,11 +25,11 @@ class HandlerMgr : public a8::Singleton<HandlerMgr>
|
||||
|
||||
void ProcGMMsg(unsigned long saddr, int sockhandle,
|
||||
const std::string& url, const std::string& quyerstr);
|
||||
|
||||
private:
|
||||
void RegisterNetMsgHandlers();
|
||||
void RegisterGMMsgHandler(const std::string& msgname,
|
||||
void (*)(f8::JsonHttpRequest*));
|
||||
|
||||
private:
|
||||
void RegisterNetMsgHandlers();
|
||||
|
||||
std::map<std::string, void (*)(f8::JsonHttpRequest*)> gmhandlers_;
|
||||
};
|
||||
|
@ -6,6 +6,7 @@
|
||||
#include "httpproxy.h"
|
||||
#include "app.h"
|
||||
#include "jsondatamgr.h"
|
||||
#include "handlermgr.h"
|
||||
|
||||
#include "framework/cpp/httpclientpool.h"
|
||||
|
||||
@ -19,9 +20,15 @@ struct HttpProxyRequest
|
||||
a8::XObject url_params;
|
||||
};
|
||||
|
||||
static void _ProxyCallback(f8::JsonHttpRequest* request)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void HttpProxy::Init()
|
||||
{
|
||||
request_prefix_ = "game2006_" + a8::XValue(a8::GetMilliSecond()).GetString() + "_";
|
||||
HandlerMgr::Instance()->RegisterGMMsgHandler("Proxy@callback", _ProxyCallback);
|
||||
}
|
||||
|
||||
void HttpProxy::UnInit()
|
||||
|
Loading…
x
Reference in New Issue
Block a user