cpp-hocon  0.3.0
Classes | Typedefs | Enumerations | Functions
hocon Namespace Reference

Factory for creating config_document instances. More...

Classes

class  abstract_config_node
 
class  abstract_config_node_value
 This is used to classify certain abstract_config_node subclasses. More...
 
struct  bad_path_exception
 Exception indicating that a path expression was invalid. More...
 
struct  bad_value_exception
 Exception indicating that a value was messed up, for example you may have asked for a duration and the value can't be sensibly parsed as a duration. More...
 
struct  bug_or_broken_exception
 Exception indicating that there's a bug in something (possibly the library itself) or the runtime environment is broken. More...
 
class  comment
 
class  config
 An immutable map from config paths to config values. More...
 
class  config_boolean
 
class  config_concatenation
 A config_concatenation represents a list of values to be concatenated (see the spec). More...
 
class  config_delayed_merge
 
class  config_delayed_merge_object
 
class  config_document
 Represents an individual HOCON or JSON file, preserving all formatting and syntax details. More...
 
class  config_double
 
struct  config_exception
 All exceptions thrown by the library are subclasses of config_exception. More...
 
class  config_include_context
 Context provided to a config_includer; this interface is only useful inside a. More...
 
class  config_includer
 Implement this interface and provide an instance to config_parse_options.set_includer() to customize handling of. More...
 
class  config_includer_file
 Implement this in addition to config_includer if you want to support inclusion of files with the. More...
 
class  config_int
 
class  config_list
 Subtype of config_value representing a list value, as in JSON's. More...
 
class  config_long
 
class  config_mergeable
 
class  config_node
 A node in the syntax tree for a HOCON or JSON document. More...
 
class  config_node_array
 
class  config_node_comment
 
class  config_node_complex_value
 
class  config_node_concatenation
 
class  config_node_field
 A field represents a key-value pair of the format "key : value", where key is a quoted or unquoted string, and value can be any node type. More...
 
class  config_node_include
 Represents an include statement of the form "include include_kind(include_path)". More...
 
class  config_node_object
 
class  config_node_path
 
class  config_node_root
 
class  config_node_simple_value
 
class  config_node_single_token
 
class  config_null
 This exists because sometimes null is not the same as missing. More...
 
class  config_number
 
class  config_object
 
class  config_origin
 Represents the origin (such as filename and line number) of a config_value for use in error messages. More...
 
class  config_parse_options
 A set of options related to parsing. More...
 
class  config_parseable
 An opaque handle to something that can be parsed, obtained from config_include_context. More...
 
class  config_reference
 
class  config_render_options
 
class  config_resolve_options
 A set of options related to resolving substitutions. More...
 
class  config_string
 
class  config_value
 An immutable value, following the JSON type schema. More...
 
class  config_value_factory
 
class  container
 An Abstractconfig_value which contains other values. More...
 
class  default_transformer
 
class  double_slash_comment
 
class  file_name_source
 
class  full_includer
 
struct  generic_exception
 Exception that doesn't fall into any other category. More...
 
class  hash_comment
 
class  ignored_whitespace
 
struct  io_exception
 Exception indicating that there was an IO error. More...
 
class  iterator
 
class  iterator_wrapper
 
class  line
 
struct  missing_exception
 Exception indicates that the setting was never set to anything, not even null. More...
 
class  name_source
 
struct  not_possible_to_resolve_exception
 
struct  not_resolved_exception
 Exception indicating that you tried to use a function that requires substitutions to be resolved, but substitutions have not been resolved (that is, config#resolve was not called). More...
 
struct  null_exception
 Exception indicates that the setting was treated as missing because it was set to null. More...
 
struct  parse_exception
 Exception indicating that there was a parse error. More...
 
class  parseable
 
class  parseable_file
 
class  parseable_not_found
 
class  parseable_resources
 
class  parseable_string
 
class  path
 
class  path_builder
 
class  path_parser
 
class  problem
 
class  problem_exception
 
class  relative_name_source
 
class  replaceable_merge_stack
 
class  resolve_context
 
struct  resolve_result
 
class  resolve_source
 
class  simple_config_document
 
class  simple_config_list
 
class  simple_config_object
 
class  simple_config_origin
 
class  simple_include_context
 
class  simple_includer
 
class  single_token_iterator
 
class  substitution
 
class  substitution_expression
 
class  token
 
class  token_iterator
 
class  token_list_iterator
 
class  tokens
 
class  unmergeable
 Interface that tags a config_value that is not mergeable until after substitutions are resolved. More...
 
class  unquoted_text
 
struct  unresolved_substitution_exception
 Exception indicating that a substitution did not resolve to anything. More...
 
struct  unsupported_exception
 
struct  validation_failed_exception
 Exception indicating that config#check_valid found validity problems. More...
 
struct  validation_problem
 Information about a problem that occurred in config#check_valid. More...
 
class  value
 
struct  wrong_type_exception
 Exception indicating that the type of a value does not match the type you requested. More...
 

Typedefs

using duration = std::pair< int64_t, int >
 A duration represented as a 64-bit integer of seconds plus a 32-bit number of nanoseconds representing a fraction of a second. More...
 
using shared_config = std::shared_ptr< const config >
 
using shared_object = std::shared_ptr< const config_object >
 
using shared_origin = std::shared_ptr< const config_origin >
 
using shared_value = std::shared_ptr< const config_value >
 
using shared_list = std::shared_ptr< const config_list >
 
typedef boost::make_recursive_variant< boost::blank, std::string, int64_t, double, int, bool, std::vector< boost::recursive_variant_ >, std::unordered_map< std::string, boost::recursive_variant_ > >::type unwrapped_value
 
using shared_container = std::shared_ptr< const container >
 
using shared_node = std::shared_ptr< const abstract_config_node >
 
using shared_node_list = std::vector< shared_node >
 
using shared_string = std::shared_ptr< const std::string >
 
using shared_includer = std::shared_ptr< const config_includer >
 
using shared_include_context = std::shared_ptr< const config_include_context >
 
using shared_parseable = std::shared_ptr< const config_parseable >
 
using shared_node_value = std::shared_ptr< const abstract_config_node_value >
 
using shared_node_array = std::shared_ptr< const config_node_array >
 
using shared_node_concatenation = std::shared_ptr< const config_node_concatenation >
 
using shared_node_object = std::shared_ptr< const config_node_object >
 
using shared_token = std::shared_ptr< const token >
 
using token_list = std::vector< shared_token >
 

Enumerations

enum  time_unit {
  NANOSECONDS, MICROSECONDS, MILLISECONDS, SECONDS,
  MINUTES, HOURS, DAYS
}
 
enum  resolve_status { RESOLVED, UNRESOLVED }
 
enum  config_include_kind { URL, FILE, CLASSPATH, HEURISTIC }
 
enum  origin_type { GENERIC, FILE, RESOURCE }
 
enum  token_type {
  START, END, COMMA, EQUALS,
  COLON, OPEN_CURLY, CLOSE_CURLY, OPEN_SQUARE,
  CLOSE_SQUARE, VALUE, NEWLINE, UNQUOTED_TEXT,
  IGNORED_WHITESPACE, SUBSTITUTION, PROBLEM, COMMENT,
  PLUS_EQUALS
}
 
enum  config_string_type { QUOTED, UNQUOTED }
 

Functions

bool operator== (config_document const &lhs, config_document const &rhs)
 Config documents compare via rendered strings. More...
 
bool is_whitespace (char codepoint)
 
bool is_whitespace_not_newline (char codepoint)
 
bool is_C0_control (char c)
 
std::string render_json_string (std::string const &s)
 
std::string render_string_unquoted_if_possible (std::string const &s)
 
template<typename T >
static resolve_result< shared_value > make_resolve_result (resolve_context context, T value)
 

Detailed Description

Factory for creating config_document instances.

The root namespace for cpp-hocon.

Typedef Documentation

◆ duration

using hocon::duration = typedef std::pair<int64_t, int>

A duration represented as a 64-bit integer of seconds plus a 32-bit number of nanoseconds representing a fraction of a second.

Definition at line 21 of file types.hpp.

Function Documentation

◆ operator==()

bool hocon::operator== ( config_document const &  lhs,
config_document const &  rhs 
)

Config documents compare via rendered strings.