#pragma once

#include <QObject>
#include <QList>

#include "organization.h"


class Config : public QObject
{
    Q_OBJECT
public:
    explicit Config(QObject *parent = nullptr);
    static void upgrade();
    static void load();

    static QString InterSoftwareFilterPath();
    static QString SoftwareFilterPath();
    static QString HistoryPath();
    static QString ConfigPath();
    static QString LogPath();
    static QString ClientDataPath();
    static QString UserDataPath();
    static QString UserDataPathLessThanV_1_2();
    static QString UserDataBackupPathLessThanV_1_2();

    static void formJson(const QByteArray &data);

    static QString logPostURL();
    static QString infoPostURL();
    static QString versionURL();
    static QString multivariateURL();
    static QString softwareFilterURL();
    static QString areacode();
    static bool autoUpgrade();
    static bool delayCommit();
    static int autoUpgradeInterval();
    static int autoCommitInterval();
    static int autoMultivariateInterval();
    static QList<Organization> organizations();
};

