summaryrefslogtreecommitdiffstats
path: root/api/logic/java/JavaVersion.h
diff options
context:
space:
mode:
Diffstat (limited to 'api/logic/java/JavaVersion.h')
-rw-r--r--api/logic/java/JavaVersion.h30
1 files changed, 30 insertions, 0 deletions
diff --git a/api/logic/java/JavaVersion.h b/api/logic/java/JavaVersion.h
new file mode 100644
index 00000000..f9a733d3
--- /dev/null
+++ b/api/logic/java/JavaVersion.h
@@ -0,0 +1,30 @@
+#pragma once
+
+#include "multimc_logic_export.h"
+#include <QString>
+
+class MULTIMC_LOGIC_EXPORT JavaVersion
+{
+ friend class JavaVersionTest;
+public:
+ JavaVersion() {};
+ JavaVersion(const QString & 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();
+
+private:
+ QString string;
+ int major = 0;
+ int minor = 0;
+ int security = 0;
+ bool parseable = false;
+ QString prerelease;
+};