argon  0.12.0
Command line argument parser
Argument.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #include <argon/Export.hpp>
4 
5 #include <string>
6 
7 namespace argon {
8 
10 
13 class ARGON_EXPORT Argument {
14 protected:
15  static constexpr int m_format_width { 24 };
16 
17  std::string m_description; // NOLINT(cppcoreguidelines-non-private-member-variables-in-classes)
18 
19 public:
20  Argument(std::string description);
21  virtual ~Argument() = default;
22  Argument(const Argument&) = default;
23  Argument(Argument&&) noexcept = default;
24  Argument& operator=(const Argument&) = default;
25  Argument& operator=(Argument&&) noexcept = default;
26 
27  [[nodiscard]] virtual auto format() const -> std::string = 0;
28 };
29 
30 }
Base type of all arguments.
Definition: Argument.hpp:13