//******************************************************************* // // $Workfile: AppVersion.h $ // // $Modtime: 8/15/04 7:59a $ // // Header for AddVersion class. // // This class provides application version number handling. // #pragma once #if _MSC_VER == 1200 #pragma warning(push, 3) // turn off some STL warnings in VS6 #endif #include <iostream> #include "boost\operators.hpp" #if _MSC_VER == 1200 #pragma warning(pop) #endif //******************************************************************* // class AppVersion : public CObject, public boost::totally_ordered<AppVersion> { DECLARE_SERIAL(AppVersion) public : AppVersion(); AppVersion(unsigned long Major, unsigned long Minor, unsigned long Build, unsigned long Revision); AppVersion(const AppVersion& b); virtual ~AppVersion(); AppVersion& operator=(const AppVersion& b); bool operator<(const AppVersion& b) const; bool operator==(const AppVersion& b) const; unsigned long GetMajor() const; unsigned long GetMinor() const; unsigned long GetBuild() const; unsigned long GetRevision() const; virtual void Serialize(CArchive& ar); #if defined _DEBUG virtual void Dump(CDumpContext& dc) const; #endif private : unsigned long m_Major; unsigned long m_Minor; unsigned long m_Build; unsigned long m_Revision; }; //******************************************************************* // // AppVersion support functions // const CString GetText(const AppVersion& AV); std::ostream& operator<<(std::ostream& os, const AppVersion& AV);
By viewing downloads associated with this article you agree to the Terms of use and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.
This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.
A list of licenses authors might use can be found here
Skills that self-taught computer programmers lack