var searchIndex = {}; searchIndex["config_file_handler"] = {"doc":"# Config File Handler","items":[[3,"FileHandler","config_file_handler","Struct for reading and writing config files.",null,null],[3,"ScopedUserAppDirRemover","","RAII object which removes the [`user_app_dir()`](fn.user_app_dir.html) when an instance is\ndropped.",null,null],[4,"Error","","Error types.",null,null],[13,"EnvError","","Wrapper for a `::std::env::VarError`",0,null],[13,"Io","","Wrapper for a `::std::io::Error`",0,null],[13,"JsonDecoderError","","Wrapper for a `::rustc_serialize::json::DecoderError`",0,null],[13,"JsonEncoderError","","Wrapper for a `::rustc_serialize::json::EncoderError`",0,null],[13,"JsonParserError","","Wrapper for a `rustc_serialize::json::ParserError`",0,null],[5,"current_bin_dir","","The full path to the directory containing the currently-running binary. See also [an example\nconfig file flowchart]\n(https://github.com/maidsafe/crust/blob/master/docs/vault_config_file_flowchart.pdf).",null,{"inputs":[],"output":{"name":"result"}}],[5,"user_app_dir","","The full path to an application support directory for the current user. See also [an example\nconfig file flowchart]\n(https://github.com/maidsafe/crust/blob/master/docs/vault_config_file_flowchart.pdf).",null,{"inputs":[],"output":{"name":"result"}}],[5,"system_cache_dir","","The full path to a system cache directory available for all users. See also [an example config\nfile flowchart]\n(https://github.com/maidsafe/crust/blob/master/docs/vault_config_file_flowchart.pdf).",null,{"inputs":[],"output":{"name":"result"}}],[5,"exe_file_stem","","The file name of the currently-running binary without any suffix or extension. For example, if\nthe binary is "C:\\\\Abc.exe" this function will return `Ok("Abc")`.",null,{"inputs":[],"output":{"name":"result"}}],[5,"cleanup","","Remove the file from every location where it can be read.",null,{"inputs":[{"name":"s"}],"output":{"name":"result"}}],[11,"fmt","","",0,null],[11,"fmt","","",0,null],[11,"description","","",0,null],[11,"cause","","",0,null],[11,"from","","",0,{"inputs":[{"name":"varerror"}],"output":{"name":"error"}}],[11,"from","","",0,{"inputs":[{"name":"error"}],"output":{"name":"error"}}],[11,"from","","",0,{"inputs":[{"name":"decodererror"}],"output":{"name":"error"}}],[11,"from","","",0,{"inputs":[{"name":"encodererror"}],"output":{"name":"error"}}],[11,"from","","",0,{"inputs":[{"name":"parsererror"}],"output":{"name":"error"}}],[11,"open","","Constructor taking the required file name (not the full path)\nThis function will return an error if the file does not exist.",1,{"inputs":[{"name":"s"},{"name":"bool"}],"output":{"name":"result"}}],[11,"path","","Get the full path to the file.",1,null],[11,"new","","Constructor taking the required file name (not the full path)\nThe config file will be initialised to a default if it does not exist.",1,{"inputs":[{"name":"s"},{"name":"bool"}],"output":{"name":"result"}}],[11,"read_file","","Read the contents of the file and decode it as JSON.",1,null],[11,"write_file","","Write `contents` to the file as JSON.",1,null],[11,"drop","","",2,null]],"paths":[[4,"Error"],[3,"FileHandler"],[3,"ScopedUserAppDirRemover"]]}; initSearch(searchIndex);