summaryrefslogtreecommitdiffstats
path: root/logic/minecraft/VersionBuilder.h
diff options
context:
space:
mode:
authorPetr Mrázek <peterix@gmail.com>2015-01-27 22:31:07 +0100
committerPetr Mrázek <peterix@gmail.com>2015-04-02 00:14:06 +0200
commit791221e923586bb717396ecf18bd13e57034df99 (patch)
tree9f608af07375b38626c8964671620477158341ba /logic/minecraft/VersionBuilder.h
parent593111b14463e9d5d08256061b981b5ab1cfb710 (diff)
downloadMultiMC-791221e923586bb717396ecf18bd13e57034df99.tar
MultiMC-791221e923586bb717396ecf18bd13e57034df99.tar.gz
MultiMC-791221e923586bb717396ecf18bd13e57034df99.tar.lz
MultiMC-791221e923586bb717396ecf18bd13e57034df99.tar.xz
MultiMC-791221e923586bb717396ecf18bd13e57034df99.zip
NOISSUE Refactors and moving of things
Diffstat (limited to 'logic/minecraft/VersionBuilder.h')
-rw-r--r--logic/minecraft/VersionBuilder.h27
1 files changed, 7 insertions, 20 deletions
diff --git a/logic/minecraft/VersionBuilder.h b/logic/minecraft/VersionBuilder.h
index 2f7e6b6b..b2d23da5 100644
--- a/logic/minecraft/VersionBuilder.h
+++ b/logic/minecraft/VersionBuilder.h
@@ -19,38 +19,25 @@
#include <QMap>
#include "VersionFile.h"
-class InstanceVersion;
+class MinecraftProfile;
class OneSixInstance;
class QJsonObject;
class QFileInfo;
-typedef QStringList PatchOrder;
-
class VersionBuilder
{
VersionBuilder();
public:
- static void build(InstanceVersion *version, OneSixInstance *instance, const QStringList &external);
- static void readJsonAndApplyToVersion(InstanceVersion *version, const QJsonObject &obj);
- static VersionFilePtr parseJsonFile(const QFileInfo &fileInfo, const bool requireOrder, bool isFTB = false);
- static VersionFilePtr parseBinaryJsonFile(const QFileInfo &fileInfo);
-
- bool readOverrideOrders(OneSixInstance *instance, PatchOrder &order);
- static bool writeOverrideOrders(OneSixInstance *instance, const PatchOrder &order);
+ static void build(MinecraftProfile *version, OneSixInstance *instance);
+ static void readJsonAndApplyToVersion(MinecraftProfile *version, const QJsonObject &obj);
private:
- InstanceVersion *m_version;
+ MinecraftProfile *m_version;
OneSixInstance *m_instance;
- QStringList external_patches;
- QDir instance_root;
-
+
void buildInternal();
- void buildFromExternalPatches();
- void buildFromCustomJson();
- void buildFromVersionJson();
- void buildFromMultilayer();
-
+
void readInstancePatches();
-
+
void readJsonAndApply(const QJsonObject &obj);
};