cpp-hocon 0.3.0
Loading...
Searching...
No Matches
config_mergeable.hpp
1#pragma once
2
3#include <memory>
4#include "export.h"
5
6namespace hocon {
7
8 class LIBCPP_HOCON_EXPORT config_mergeable {
9 friend class config_value;
10 public:
62 virtual std::shared_ptr<const config_mergeable> with_fallback(std::shared_ptr<const config_mergeable> other) const = 0;
63
64 protected:
69 virtual shared_value to_fallback_value() const = 0;
70 };
71
72} // namespace hocon
virtual shared_value to_fallback_value() const =0
Converts a config to its root object and a config_value to itself.
virtual std::shared_ptr< const config_mergeable > with_fallback(std::shared_ptr< const config_mergeable > other) const =0
Returns a new value computed by merging this value with another, with keys in this value "winning" ov...
An immutable value, following the JSON type schema.
Factory for creating config_document instances.
Definition: config.hpp:18