var searchIndex = {}; searchIndex["config"] = {"doc":"A library to parse and load configuration files.","items":[[0,"types","config","Internal types used to represent a configuration and corresponding primitives to browse it",null,null],[3,"Config","config::types","The top-level `Config` type that represents a configuration",null,null],[3,"Setting","","A `Setting` representation. Settings have a name and a value.",null,null],[12,"name","","Setting name, as read from the configuration file",0,null],[12,"value","","This setting's value. A value can be a scalar, an array, a list, or a group.",0,null],[4,"Value","","A type representing a generic value. `Setting`s store `Value`s.",null,null],[13,"Svalue","","A scalar",1,null],[13,"Array","","An array",1,null],[13,"List","","A list. Arrays can only store scalars of the same type, whereas lists store `Value`s of\npossibly different types, including other lists.",1,null],[13,"Group","","A group. Basically, a group acts as another configuration file - it stores a `SettingsList`.",1,null],[4,"ScalarValue","","The scalar values representation. Scalar values bind directly to Rust primitive types.",null,null],[13,"Boolean","","A boolean scalar",2,null],[13,"Integer32","","An i32 scalar",2,null],[13,"Integer64","","An i64 scalar",2,null],[13,"Floating32","","An f32 scalar",2,null],[13,"Floating64","","An f64 scalar",2,null],[13,"Str","","A string scalar",2,null],[6,"SettingsList","","Settings list representation. Associates settings to their names.",null,null],[6,"ArrayValue","","The type used to represent the scalars inside an array.\nAn array can only store scalar values of the same type.",null,null],[6,"ListValue","","The type used to represent the generic values inside a list.\nLists are heterogeneous and can store any type of value, including other lists.",null,null],[11,"eq","","",3,null],[11,"ne","","",3,null],[11,"fmt","","",3,null],[11,"eq","","",0,null],[11,"ne","","",0,null],[11,"fmt","","",0,null],[11,"eq","","",1,null],[11,"ne","","",1,null],[11,"fmt","","",1,null],[11,"eq","","",2,null],[11,"ne","","",2,null],[11,"fmt","","",2,null],[11,"new","","Creates a new wrapper `Config` to hold a `SettingsList`",3,{"inputs":[{"name":"settingslist"}],"output":{"name":"config"}}],[11,"lookup","","Looks up a value in a configuration. A path is a dot-separated list of settings\ndescribing the path of the desired value in the configuration.\nReturns `None` if the path is invalid. A path is invalid if it is not syntactically\nwell-formed, if it attempts to index an array or list beyond the limit, or if it\nincludes an unknown setting.\n# Examples\nSuppose we have loaded a configuration that consists of:",3,null],[11,"lookup_boolean","","A convenient wrapper around `lookup()` that unwraps the underlying primitive\ntype of a generic `Value`.",3,null],[11,"lookup_integer32","","A convenient wrapper around `lookup()` that unwraps the underlying primitive\ntype of a generic `Value`.",3,null],[11,"lookup_integer64","","A convenient wrapper around `lookup()` that unwraps the underlying primitive\ntype of a generic `Value`.",3,null],[11,"lookup_floating32","","A convenient wrapper around `lookup()` that unwraps the underlying primitive\ntype of a generic `Value`.",3,null],[11,"lookup_floating64","","A convenient wrapper around `lookup()` that unwraps the underlying primitive\ntype of a generic `Value`.",3,null],[11,"lookup_str","","A convenient wrapper around `lookup()` that unwraps the underlying primitive\ntype of a generic `Value`.",3,null],[11,"lookup_boolean_or","","A convenient wrapper around `lookup_boolean()` that unwraps the underlying primitive\ntype of a boolean `Value`.",3,null],[11,"lookup_integer32_or","","A convenient wrapper around `lookup_integer32()` that unwraps the underlying primitive\ntype of an integer32 `Value`.",3,null],[11,"lookup_integer64_or","","A convenient wrapper around `lookup_integer64()` that unwraps the underlying primitive\ntype of an integer64 `Value`.",3,null],[11,"lookup_floating32_or","","A convenient wrapper around `lookup_floating32()` that unwraps the underlying primitive\ntype of an floating32 `Value`.",3,null],[11,"lookup_floating64_or","","A convenient wrapper around `lookup_floating64()` that unwraps the underlying primitive\ntype of an floating64 `Value`. If either of `lookup_floating64()` or `lookup` return `None`,\nthen the user-provided default value is returned.",3,null],[11,"lookup_str_or","","A convenient wrapper around `lookup_str()` that unwraps the underlying primitive\ntype of a string `Value`.",3,null],[11,"from_str","","",3,{"inputs":[{"name":"str"}],"output":{"name":"result"}}],[11,"new","","Creates a new setting with a given name and value\n# Examples \nLet's say we want to create a setting to store an `i32`.\nWe start by creating a `ScalarValue`:",0,{"inputs":[{"name":"string"},{"name":"value"}],"output":{"name":"setting"}}],[11,"to_string","","",2,null],[0,"error","config","Errors that can occur while parsing a configuration",null,null],[3,"ConfigError","config::error","A generic configuration error type",null,null],[12,"kind","","Indicates what kind of error this is",4,null],[12,"desc","","A descriptive message about the error",4,null],[12,"detail","","Error details, if available",4,null],[4,"ConfigErrorKind","","Possible error kinds",null,null],[13,"IoError","","An I/O error. Can only occur if reading from a stream (file, socket, etc.)",5,null],[13,"ParseError","","A syntax error",5,null],[5,"from_io_err","","Converts an I/O Error into a `ConfigError`",null,{"inputs":[{"name":"ioerror"}],"output":{"name":"configerror"}}],[5,"from_parse_err","","Converts a `ParseError` into a `ConfigError`",null,{"inputs":[{"name":"parseerror"}],"output":{"name":"configerror"}}],[11,"fmt","","",4,null],[11,"fmt","","",5,null],[11,"eq","","",5,null],[11,"fmt","","",4,null],[11,"description","","",4,null],[0,"reader","config","Reader types to parse a configuration.",null,null],[5,"from_stream","config::reader","Reads a configuration from a generic stream.\nErrors can be caused by:",null,{"inputs":[{"name":"t"}],"output":{"name":"result"}}],[5,"from_file","","Reads a configuration from a UTF-8 file.\nErrors can be caused by:",null,{"inputs":[{"name":"path"}],"output":{"name":"result"}}],[5,"from_str","","Reads a configuration from a string slice.\nThe only possible error that can occur is a syntax error.\n# Examples",null,{"inputs":[{"name":"str"}],"output":{"name":"result"}}]],"paths":[[3,"Setting"],[4,"Value"],[4,"ScalarValue"],[3,"Config"],[3,"ConfigError"],[4,"ConfigErrorKind"]]}; initSearch(searchIndex);