DriveHQ Start Menu
Cloud Drive Mapping
Folder Sync
True Drop Box
FTP/SFTP Hosting
Group Account
Team Anywhere
DriveHQ Start Menu
Online File Server
My Storage
|
Manage Shares
|
Publishes
|
Drop Boxes
|
Group Account
WebDAV Drive Mapping
Cloud Drive Home
|
WebDAV Guide
|
Drive Mapping Tool
|
Drive Mapping URL
Complete Data Backup
Backup Guide
|
Cloud-to-Cloud Backup
|
DVR/Camera Backup
FTP, Email & Web Service
FTP/SFTP Hosting
|
Email Hosting
|
Web Hosting
|
Webcam Hosting
Other Products & Services
Team Anywhere
|
Connect to Remote PC
|
Cloud Surveillance
|
Virtual CCTV NVR
Quick Links
Security and Privacy
Customer Support
Service Manual
Use Cases
Group Account
Online Help
Support Forum
Contact Us
About DriveHQ
Sign Up
Login
Features
Business Features
Online File Server
FTP Hosting
Cloud Drive Mapping
Cloud File Backup
Email Backup & Hosting
Cloud File Sharing
Folder Synchronization
Group Management
True Drop Box
Full-text Search
AD Integration/SSO
Mobile Access
Personal Features
Personal Cloud Drive
Backup All Devices
Mobile APPs
Personal Web Hosting
Sub-Account (for Kids)
Home/PC/Kids Monitoring
Other Features
Team Anywhere (Remote Desktop Service)
CameraFTP Cloud Surveillance
Software
DriveHQ Drive Mapping Tool
DriveHQ FileManager
DriveHQ Online Backup
DriveHQ Team Anywhere for Windows (Beta)
DriveHQ Mobile Apps
Pricing
Business Plans & Pricing
Personal Plans & Pricing
Price Comparison with Others
Feature Comparison with Others
Install Mobile App
Sign up
Creating account...
Invalid character in username! Only 0-9, a-z, A-Z, _, -, . allowed.
Username is required!
Invalid email address!
E-mail is required!
Password is required!
Password is invalid!
Password and confirmation do not match.
Confirm password is required!
I accept
Membership Agreement
Please read the Membership Agreement and check "I accept"!
Free Quick Sign-up
Sign-up Page
Log in
Signing in...
Username or e-mail address is required!
Password is required!
Keep me logged in
Quick Login
Forgot Password
Up
Upload
Download
Share
Publish
New Folder
New File
Copy
Cut
Delete
Paste
Rate
Upgrade
Rotate
Effect
Edit
Slide
History
/* * OgreMaxViewer - An Ogre 3D-based viewer for .scene and .mesh files * Copyright 2008 Derek Nedelman * * This code is available under the OgreMax Free License: * -You may use this code for any purpose, commercial or non-commercial. * -If distributing derived works (that use this source code) in binary or source code form, * you must give the following credit in your work's end-user documentation: * "Portions of this work provided by OgreMax (www.ogremax.com)" * * Derek Nedelman assumes no responsibility for any harm caused by using this code. * * OgreMaxViewer was written by Derek Nedelman and released at www.ogremax.com */ #ifndef OgreMax_Version_INCLUDED #define OgreMax_Version_INCLUDED //Includes--------------------------------------------------------------------- #include
#include "OgreMaxPlatform.hpp" //Classes---------------------------------------------------------------------- namespace OgreMax { /** * A major/minor/build/revision number collection. * Use the Version class to simplify the storage and comparison of version numbers */ class _OgreMaxExport Version { public: /** Default class constructor. Constructs a Version object with all zeroes. */ Version(); /** * Constructs a Version from the major, minor, build, and revision numbers. * All components should be less than 0 * @param major [in] - Major version number. * @param minor [in] - Minor version number. * @param patch [in] - Patch number. */ Version(int major, int minor = 0, int patch = 0); /** * Constructs a version by parsing it from a string * @param version [in] - The string to parse. The string should be of the form: 'xx.xx.xx'. * All components are optional. */ Version(const Ogre::String& version); /** * Gets the major version number. */ int GetMajor() const; /** * Gets the minor version number. */ int GetMinor() const; /** * Gets the patch number. */ int GetPatch() const; /** * Converts the version to a string. * @param text [out] - The string result. */ void ToString(Ogre::String& text) const; /** * Converts the version to a string. */ Ogre::String ToString() const; /** * Converts the version to an integer. * Each component can be no larger than 99 for this to work properly */ int ToInt() const; //Comparison operators bool operator == (const Version& v) const {return Compare(*this, v) == 0;} bool operator < (const Version& v) const {return Compare(*this, v) < 0;} bool operator <= (const Version& v) const {return Compare(*this, v) <= 0;} bool operator > (const Version& v) const {return Compare(*this, v) > 0;} bool operator >= (const Version& v) const {return Compare(*this, v) >= 0;} /** * Compares two versions. * Function for comparing two Version objects, returning an * integer to indicate the result of the comparison. * @param version1 [in] - The first Version to compare. * @param version2 [in] - The second Version to compare to. * @return An integer indicating the result of the comparison. * This value is less than 0 if version1 is "older" than version2, * greater than 0 if version1 is "newer" than version2, and equal to * 0 if the two versions are the same. */ static int Compare(const Version& version1, const Version& version2); private: enum { MAJOR, MINOR, PATCH, MAX_COMPONENTS }; /** Major, minor, patch */ int components[MAX_COMPONENTS]; }; } #endif
Version.hpp
Page URL
File URL
Prev
8/8 Next
Download
( 4 KB )
Note: The DriveHQ service banners will NOT be displayed if the file owner is a paid member.
Comments
Total ratings:
0
Average rating:
Not Rated
Would you like to comment?
Join DriveHQ
for a free account, or
Logon
if you are already a member.