DPP-MySQL
An extremely lightweight MySQL wrapper for D++ bots
config Namespace Reference

Functions

void init (const std::string &config_file)
 Initialise config file. More...
 
json & get (const std::string &key="")
 Get all config values from a specific key. More...
 
bool exists (const std::string &key)
 

Function Documentation

◆ exists()

bool config::exists ( const std::string &  key)

Returns true if the specified key exists

Parameters
key
Returns
true if key exists

◆ get()

json& config::get ( const std::string &  key = "")

Get all config values from a specific key.

Parameters
keyThe key, if empty/omitted the root node is returned
Returns
json& configuration or empty container if not found

◆ init()

void config::init ( const std::string &  config_file)

Initialise config file.

Parameters
config_fileConfig file to read