3 #include <hocon/functional_list.hpp>
4 #include <hocon/types.hpp>
13 class LIBCPP_HOCON_EXPORT
path {
16 explicit path(std::string first,
path const& remainder);
17 explicit path(std::vector<std::string> elements);
18 explicit path(std::vector<path> paths_to_concat);
20 shared_string first()
const;
28 bool has_remainder()
const;
30 shared_string last()
const;
33 path sub_path(
int remove_from_front);
34 path sub_path(
int start_index,
int end_index);
35 bool starts_with(
path other)
const;
38 bool operator!=(
path const& other)
const;
43 void append_to_string(std::string& base)
const;
51 static path new_key(std::string key);
52 static path new_path(std::string
path);
Factory for creating config_document instances.
static bool has_funky_chars(std::string const &s)
Signals whether quotes and other noise need to be removed/ignored.
bool operator==(config_document const &lhs, config_document const &rhs)
Config documents compare via rendered strings.
path parent() const
Returns the path minus the last element or null if we have just one element.
path remainder() const
Returns the path minus the first element, or null if no more elements.
std::string to_string() const
For debugging.
std::string render() const
Human-readable error-message-oriented string representation of path.