CLI11
C++11 Command Line Interface Parser
Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes | List of all members
CLI::Config Class Referenceabstract

This class provides a converter for configuration files. More...

#include <ConfigFwd.hpp>

Inheritance diagram for CLI::Config:
CLI::ConfigBase CLI::ConfigINI

Public Member Functions

virtual std::string to_config (const App *, bool, bool, std::string) const =0
 Convert an app into a configuration.
 
virtual std::vector< ConfigItemfrom_config (std::istream &) const =0
 Convert a configuration into an app.
 
virtual CLI11_NODISCARD std::string to_flag (const ConfigItem &item) const
 Get a flag value.
 
CLI11_NODISCARD std::vector< ConfigItemfrom_file (const std::string &name) const
 Parse a config file, throw an error (ParseError:ConfigParseError or FileError) on failure.
 
virtual ~Config ()=default
 Virtual destructor.
 

Protected Attributes

std::vector< ConfigItemitems {}
 

Detailed Description

This class provides a converter for configuration files.

Member Function Documentation

◆ from_config()

virtual std::vector< ConfigItem > CLI::Config::from_config ( std::istream &  ) const
pure virtual

Convert a configuration into an app.

Implemented in CLI::ConfigBase.

◆ to_config()

virtual std::string CLI::Config::to_config ( const App ,
bool  ,
bool  ,
std::string   
) const
pure virtual

Convert an app into a configuration.

Implemented in CLI::ConfigBase.


The documentation for this class was generated from the following file: