aboutsummaryrefslogtreecommitdiff
path: root/launcher/java/JavaVersion.h
diff options
context:
space:
mode:
authorSefa Eyeoglu <contact@scrumplex.net>2023-08-04 19:42:36 +0200
committerGitHub <noreply@github.com>2023-08-04 19:42:36 +0200
commitae793f6cf11658c9abc5111e82d5ba7b3e6af127 (patch)
treeed41f30e2c0f02e4be1d42324b3f05fbab75b2cd /launcher/java/JavaVersion.h
parent50c7d39e082f0a7dbd977401e16d5adf534d9770 (diff)
parent1d638e018ac40fbfb35dd117f9a948c0cf35eadd (diff)
downloadPrismLauncher-ae793f6cf11658c9abc5111e82d5ba7b3e6af127.tar.gz
PrismLauncher-ae793f6cf11658c9abc5111e82d5ba7b3e6af127.tar.bz2
PrismLauncher-ae793f6cf11658c9abc5111e82d5ba7b3e6af127.zip
Merge pull request #1459 from Scrumplex/format
Diffstat (limited to 'launcher/java/JavaVersion.h')
-rw-r--r--launcher/java/JavaVersion.h44
1 files changed, 18 insertions, 26 deletions
diff --git a/launcher/java/JavaVersion.h b/launcher/java/JavaVersion.h
index 9bbf0642..69473203 100644
--- a/launcher/java/JavaVersion.h
+++ b/launcher/java/JavaVersion.h
@@ -4,42 +4,34 @@
// NOTE: apparently the GNU C library pollutes the global namespace with these... undef them.
#ifdef major
- #undef major
+#undef major
#endif
#ifdef minor
- #undef minor
+#undef minor
#endif
-class JavaVersion
-{
+class JavaVersion {
friend class JavaVersionTest;
-public:
- JavaVersion() {};
- JavaVersion(const QString & rhs);
- JavaVersion & operator=(const QString & rhs);
+ public:
+ JavaVersion(){};
+ JavaVersion(const QString& rhs);
- bool operator<(const JavaVersion & rhs);
- bool operator==(const JavaVersion & rhs);
- bool operator>(const JavaVersion & rhs);
+ JavaVersion& operator=(const QString& rhs);
+
+ bool operator<(const JavaVersion& rhs);
+ bool operator==(const JavaVersion& rhs);
+ bool operator>(const JavaVersion& rhs);
bool requiresPermGen();
- QString toString();
-
- int major()
- {
- return m_major;
- }
- int minor()
- {
- return m_minor;
- }
- int security()
- {
- return m_security;
- }
-private:
+ QString toString() const;
+
+ int major() { return m_major; }
+ int minor() { return m_minor; }
+ int security() { return m_security; }
+
+ private:
QString m_string;
int m_major = 0;
int m_minor = 0;