2019-11-08 22:06:09 -05:00
|
|
|
#ifndef MODULE_H
|
|
|
|
#define MODULE_H
|
2019-09-06 23:43:07 -04:00
|
|
|
|
|
|
|
// This file is part of MRCI.
|
|
|
|
|
|
|
|
// MRCI is free software: you can redistribute it and/or modify
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
|
|
// (at your option) any later version.
|
|
|
|
|
|
|
|
// MRCI is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
// GNU General Public License for more details.
|
|
|
|
|
|
|
|
// You should have received a copy of the GNU General Public License
|
|
|
|
// along with MRCI under the LICENSE.md file. If not, see
|
|
|
|
// <http://www.gnu.org/licenses/>.
|
|
|
|
|
|
|
|
#include "common.h"
|
2019-11-08 22:06:09 -05:00
|
|
|
#include "cmd_object.h"
|
2019-09-06 23:43:07 -04:00
|
|
|
#include "commands/admin.h"
|
|
|
|
#include "commands/bans.h"
|
|
|
|
#include "commands/cast.h"
|
|
|
|
#include "commands/info.h"
|
|
|
|
#include "commands/mods.h"
|
|
|
|
#include "commands/users.h"
|
|
|
|
#include "commands/auth.h"
|
|
|
|
#include "commands/cmd_ranks.h"
|
|
|
|
#include "commands/acct_recovery.h"
|
|
|
|
#include "commands/fs.h"
|
|
|
|
#include "commands/certs.h"
|
|
|
|
#include "commands/p2p.h"
|
|
|
|
#include "commands/channels.h"
|
|
|
|
|
2019-11-08 22:06:09 -05:00
|
|
|
class Module : public QObject
|
2019-09-06 23:43:07 -04:00
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
2019-11-08 22:06:09 -05:00
|
|
|
bool pubReg;
|
|
|
|
bool emailConfirmation;
|
|
|
|
bool passwrdResets;
|
2019-09-06 23:43:07 -04:00
|
|
|
|
2019-11-08 22:06:09 -05:00
|
|
|
bool runCmd(const QString &name);
|
|
|
|
void listCmds(const QStringList &list);
|
|
|
|
void loadSettings();
|
|
|
|
QStringList userCmdList();
|
|
|
|
QStringList pubCmdList();
|
|
|
|
QStringList rankExemptList();
|
2019-09-06 23:43:07 -04:00
|
|
|
|
|
|
|
public:
|
|
|
|
|
2019-11-08 22:06:09 -05:00
|
|
|
explicit Module(QObject *parent = nullptr);
|
2019-09-06 23:43:07 -04:00
|
|
|
|
2019-11-08 22:06:09 -05:00
|
|
|
bool start(const QStringList &args);
|
2019-09-06 23:43:07 -04:00
|
|
|
};
|
|
|
|
|
2019-11-08 22:06:09 -05:00
|
|
|
#endif // MODULE_H
|