summaryrefslogtreecommitdiffstats
path: root/logic/java/JavaVersion.h
blob: f9a733d3052315fc8cac6bdda2fcc18e92681e9f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
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;
};