CLI11
C++11 Command Line Interface Parser
Loading...
Searching...
No Matches
Config.hpp
1// Copyright (c) 2017-2024, 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// IWYU pragma: private, include "CLI/CLI.hpp"
10
11// [CLI11:public_includes:set]
12#include <algorithm>
13#include <cctype>
14#include <fstream>
15#include <iostream>
16#include <string>
17#include <utility>
18#include <vector>
19// [CLI11:public_includes:end]
20
21#include "App.hpp"
22#include "ConfigFwd.hpp"
23#include "StringTools.hpp"
24
25namespace CLI {
26// [CLI11:config_hpp:verbatim]
27namespace detail {
28
29std::string convert_arg_for_ini(const std::string &arg,
30 char stringQuote = '"',
31 char literalQuote = '\'',
32 bool disable_multi_line = false);
33
35std::string ini_join(const std::vector<std::string> &args,
36 char sepChar = ',',
37 char arrayStart = '[',
38 char arrayEnd = ']',
39 char stringQuote = '"',
40 char literalQuote = '\'');
41
42void clean_name_string(std::string &name, const std::string &keyChars);
43
44std::vector<std::string> generate_parents(const std::string &section, std::string &name, char parentSeparator);
45
47void checkParentSegments(std::vector<ConfigItem> &output, const std::string &currentSection, char parentSeparator);
48} // namespace detail
49
50// [CLI11:config_hpp:end]
51} // namespace CLI
52
53#ifndef CLI11_COMPILE
54#include "impl/Config_inl.hpp" // IWYU pragma: export
55#endif