code_app/modules/version/HGVersionImpl.hpp

28 lines
1.1 KiB
C++
Raw Normal View History

#ifndef __HGVERSIONIMPL_HPP__
#define __HGVERSIONIMPL_HPP__
#include "HGVersion.h"
#include "../base/HGThread.h"
class HGVersionMgrImpl
{
public:
HGVersionMgrImpl();
~HGVersionMgrImpl();
HGResult GetServerConfig(HGServerConfig* config);
HGResult PostInstallInfo(const HGChar* appName, const HGChar* desc);
HGResult PostUninstallInfo(const HGChar* appName, const HGChar* desc);
HGResult PostCrashInfo(const HGChar* appName, const HGChar* desc, const HGChar* crashFilePath, const HGChar* exceptionAddr);
HGResult PostUserFeedback(const HGChar* appName, const HGChar* desc, const HGChar* feedback, const HGChar* contact);
2022-07-14 01:41:51 +00:00
HGResult GetVersionList(const HGChar* appName, HGVersionInfo** info, HGUInt* count);
HGResult HttpDownload(const HGChar* url, const HGChar* saveFilePath, HGHttpDownloadFunc func, HGPointer param);
2022-07-14 01:41:51 +00:00
static HGResult ReleaseVersionList(HGVersionInfo *info, HGUInt count);
static HGResult GetCurrVersion(const HGChar* appName, HGChar* version, HGUInt maxLen);
private:
HGServerConfig m_serverCfg;
HGThread m_thread;
};
#endif /* __HGVERSIONIMPL_HPP__ */