CLI11 2.3.2
Loading...
Searching...
No Matches
Config.hpp
Go to the documentation of this file.
1// Copyright (c) 2017-2023, University of Cincinnati, developed by Henry Schreiner
2// under NSF AWARD 1414736 and by the respective contributors.
3// All rights reserved.
4//
5// SPDX-License-Identifier: BSD-3-Clause
6
7#pragma once
8
9// [CLI11:public_includes:set]
10#include <algorithm>
11#include <cctype>
12#include <fstream>
13#include <iostream>
14#include <string>
15#include <utility>
16#include <vector>
17// [CLI11:public_includes:set]
18
19#include "App.hpp"
20#include "ConfigFwd.hpp"
21#include "StringTools.hpp"
22
23namespace CLI {
24// [CLI11:config_hpp:verbatim]
25namespace detail {
26
27std::string convert_arg_for_ini(const std::string &arg, char stringQuote = '"', char characterQuote = '\'');
28
30std::string ini_join(const std::vector<std::string> &args,
31 char sepChar = ',',
32 char arrayStart = '[',
33 char arrayEnd = ']',
34 char stringQuote = '"',
35 char characterQuote = '\'');
36
37std::vector<std::string> generate_parents(const std::string &section, std::string &name, char parentSeparator);
38
40void checkParentSegments(std::vector<ConfigItem> &output, const std::string &currentSection, char parentSeparator);
41} // namespace detail
42
43// [CLI11:config_hpp:end]
44} // namespace CLI
45
46#ifndef CLI11_COMPILE
47#include "impl/Config_inl.hpp"
48#endif
std::string convert_arg_for_ini(const std::string &arg, char stringQuote='"', char characterQuote = '\'')
std::vector< std::string > generate_parents(const std::string &section, std::string &name, char parentSeparator)
std::string ini_join(const std::vector< std::string > &args, char sepChar=',', char arrayStart='[', char arrayEnd=']', char stringQuote='"', char characterQuote = '\'')
Comma separated join, adds quotes if needed.
void checkParentSegments(std::vector< ConfigItem > &output, const std::string &currentSection, char parentSeparator)
assuming non default segments do a check on the close and open of the segments in a configItem struct...
Definition App.hpp:34