pollymc/api/logic/minecraft/OneSixVersionFormat.h

30 lines
1.1 KiB
C
Raw Normal View History

#pragma once
#include <minecraft/VersionFile.h>
#include <minecraft/PackProfile.h>
#include <minecraft/Library.h>
#include <QJsonDocument>
class OneSixVersionFormat
{
public:
2018-07-15 18:21:05 +05:30
// version files / profile patches
static VersionFilePtr versionFileFromJson(const QJsonDocument &doc, const QString &filename, const bool requireOrder);
static QJsonDocument versionFileToJson(const VersionFilePtr &patch);
2018-07-15 18:21:05 +05:30
// libraries
static LibraryPtr libraryFromJson(const QJsonObject &libObj, const QString &filename);
static QJsonObject libraryToJson(Library *library);
2018-07-15 18:21:05 +05:30
// DEPRECATED: old 'plus' jar mods generated by the application
static LibraryPtr plusJarModFromJson(const QJsonObject &libObj, const QString &filename, const QString &originalName);
2018-07-15 18:21:05 +05:30
// new jar mods derived from libraries
static LibraryPtr jarModFromJson(const QJsonObject &libObj, const QString &filename);
static QJsonObject jarModtoJson(Library * jarmod);
2018-07-15 18:21:05 +05:30
// mods, also derived from libraries
static LibraryPtr modFromJson(const QJsonObject &libObj, const QString &filename);
static QJsonObject modtoJson(Library * jarmod);
};