aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/getopt/small/modchooser.h
diff options
context:
space:
mode:
authortobo <tobo@yandex-team.ru>2022-02-10 16:47:27 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:47:27 +0300
commit7fe839092527589b38f014d854c51565b3c1adfa (patch)
tree309e97022d3530044b712b8f71318c78faf7856e /library/cpp/getopt/small/modchooser.h
parentd0d68c395c10da4cb56a1c845504570a04d7893e (diff)
downloadydb-7fe839092527589b38f014d854c51565b3c1adfa.tar.gz
Restoring authorship annotation for <tobo@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/getopt/small/modchooser.h')
-rw-r--r--library/cpp/getopt/small/modchooser.h24
1 files changed, 12 insertions, 12 deletions
diff --git a/library/cpp/getopt/small/modchooser.h b/library/cpp/getopt/small/modchooser.h
index 0a8de6d50b..8e32423ab4 100644
--- a/library/cpp/getopt/small/modchooser.h
+++ b/library/cpp/getopt/small/modchooser.h
@@ -9,12 +9,12 @@
#include <functional>
//! Mode function with vector of cli arguments.
-using TMainFunctionPtrV = std::function<int(const TVector<TString>&)> ;
-using TMainFunctionRawPtrV = int (*)(const TVector<TString>& argv);
+using TMainFunctionPtrV = std::function<int(const TVector<TString>&)> ;
+using TMainFunctionRawPtrV = int (*)(const TVector<TString>& argv);
//! Mode function with classic argc and argv arguments.
-using TMainFunctionPtr = std::function<int(int, const char**)> ;
-using TMainFunctionRawPtr = int (*)(const int argc, const char** argv);
+using TMainFunctionPtr = std::function<int(int, const char**)> ;
+using TMainFunctionRawPtr = int (*)(const int argc, const char** argv);
//! Mode class with vector of cli arguments.
class TMainClassV {
@@ -26,7 +26,7 @@ public:
//! Mode class with classic argc and argv arguments.
class TMainClass {
public:
- virtual int operator()(int argc, const char** argv) = 0;
+ virtual int operator()(int argc, const char** argv) = 0;
virtual ~TMainClass() = default;
};
@@ -47,10 +47,10 @@ public:
~TModChooser();
public:
- void AddMode(const TString& mode, TMainFunctionRawPtr func, const TString& description, bool hidden = false, bool noCompletion = false);
- void AddMode(const TString& mode, TMainFunctionRawPtrV func, const TString& description, bool hidden = false, bool noCompletion = false);
- void AddMode(const TString& mode, TMainFunctionPtr func, const TString& description, bool hidden = false, bool noCompletion = false);
- void AddMode(const TString& mode, TMainFunctionPtrV func, const TString& description, bool hidden = false, bool noCompletion = false);
+ void AddMode(const TString& mode, TMainFunctionRawPtr func, const TString& description, bool hidden = false, bool noCompletion = false);
+ void AddMode(const TString& mode, TMainFunctionRawPtrV func, const TString& description, bool hidden = false, bool noCompletion = false);
+ void AddMode(const TString& mode, TMainFunctionPtr func, const TString& description, bool hidden = false, bool noCompletion = false);
+ void AddMode(const TString& mode, TMainFunctionPtrV func, const TString& description, bool hidden = false, bool noCompletion = false);
void AddMode(const TString& mode, TMainClass* func, const TString& description, bool hidden = false, bool noCompletion = false);
void AddMode(const TString& mode, TMainClassV* func, const TString& description, bool hidden = false, bool noCompletion = false);
@@ -95,7 +95,7 @@ public:
* call it and return its return code.
* 4) If appropriate mode is not found - return non-zero code.
*/
- int Run(int argc, const char** argv) const;
+ int Run(int argc, const char** argv) const;
//! Run appropriate mode. Same as Run(const int, const char**)
int Run(const TVector<TString>& argv) const;
@@ -174,7 +174,7 @@ private:
//! Mode class that allows introspecting its console arguments.
class TMainClassArgs: public TMainClass {
public:
- int operator()(int argc, const char** argv) final;
+ int operator()(int argc, const char** argv) final;
public:
//! Run this mode.
@@ -197,7 +197,7 @@ private:
//! Mode class that uses sub-modes to dispatch commands further.
class TMainClassModes: public TMainClass {
public:
- int operator()(int argc, const char** argv) final;
+ int operator()(int argc, const char** argv) final;
public:
//! Run this mode.