2025-02-09 19:58:55 +01:00
|
|
|
#pragma once
|
2025-02-05 12:48:05 +01:00
|
|
|
#include "std_lib_inc.h"
|
|
|
|
#ifndef SUBCOMMAND_H
|
|
|
|
#define SUBCOMMAND_H
|
|
|
|
|
2025-02-09 19:58:55 +01:00
|
|
|
namespace commands
|
|
|
|
{
|
|
|
|
class SubCommand
|
|
|
|
{
|
|
|
|
private:
|
2025-02-05 12:48:05 +01:00
|
|
|
string name;
|
2025-02-09 19:58:55 +01:00
|
|
|
bool show_result;
|
|
|
|
|
|
|
|
public:
|
2025-02-09 22:32:19 +01:00
|
|
|
SubCommand(const string& indicator, bool show_result);
|
2025-02-09 19:58:55 +01:00
|
|
|
string get_name();
|
|
|
|
bool should_display_result() const;
|
2025-02-09 21:14:26 +01:00
|
|
|
virtual void run(stringstream& args);
|
2025-02-05 12:48:05 +01:00
|
|
|
};
|
2025-02-09 19:58:55 +01:00
|
|
|
} // commands
|
2025-02-05 12:48:05 +01:00
|
|
|
|
|
|
|
#endif // SUBCOMMAND_H
|