3 #include <hocon/config_includer.hpp>
4 #include <hocon/config_includer_file.hpp>
5 #include <hocon/config_parse_options.hpp>
6 #include <internal/full_includer.hpp>
18 shared_object
include(shared_include_context context, std::string what)
const override;
20 shared_object include_without_fallback(shared_include_context context, std::string what)
const;
22 shared_object
include_file(shared_include_context context, std::string what)
const override;
24 static shared_object include_file_without_fallback(shared_include_context context, std::string what);
28 static shared_object from_basename(std::shared_ptr<name_source> source,
32 static std::shared_ptr<const full_includer> make_full(std::shared_ptr<const config_includer> includer);
35 shared_includer _fallback;
40 class proxy :
public full_includer,
public std::enable_shared_from_this<proxy> {
42 proxy(std::shared_ptr<const config_includer> delegate);
44 shared_includer
with_fallback(shared_includer fallback)
const;
46 shared_object
include(shared_include_context context, std::string what)
const;
48 shared_object
include_file(shared_include_context context, std::string what)
const;
50 static std::shared_ptr<const full_includer> make_full(shared_includer includer);
53 std::shared_ptr<const config_includer> _delegate;
59 name_source(shared_include_context context) : _context(move(context)) {
60 if (
nullptr != _context) {
61 _context_initialized =
true;
63 _context_initialized =
false;
67 virtual shared_parseable name_to_parseable(std::string name,
70 void set_context(shared_include_context context) {
71 if (!_context_initialized) {
72 _context_initialized =
true;
77 shared_include_context get_context()
const {
81 bool context_initialized()
const {
82 return _context_initialized;
86 shared_include_context _context;
87 bool _context_initialized;
94 shared_parseable name_to_parseable(std::string name,
104 shared_parseable name_to_parseable(std::string name,