Files
Sun1602/Tools/UpdateModule/VersionInfo.h
T
2022-10-26 12:25:11 +08:00

45 lines
848 B
C++

#pragma once
#include "define.h"
#include <string>
using namespace std;
#define IN
#define OUT
typedef unsigned char byte;
class DLL_DECLARE CVersionInfo
{
public:
CVersionInfo(void);
CVersionInfo( const CVersionInfo& obj )
{
for( int i = 0 ; i < MAX_VERSION_COUNT; i++ )
m_byVer[i] = obj.m_byVer[i];
}
~CVersionInfo(void);
private:
byte m_byVer[MAX_VERSION_COUNT];
public:
byte GetVersion( int nNum );
bool SetVersion( int nNum, byte byVer );
unsigned int GetTotalVersion();
void Init();
bool SetVersionFromString( char* pszVersion ); //01.02.03 과 같은 타입의 스트링버전으로 버전세팅
bool GetStringVersion( char* OUT pszVersion, int nSize );
public:
CVersionInfo& operator=( const CVersionInfo& obj )
{
for( int i = 0 ; i < MAX_VERSION_COUNT; i++ )
m_byVer[i] = obj.m_byVer[i];
return *this;
}
};