2018-01-25 16:24:33 +00:00
|
|
|
#ifndef LIBLLARP_CONFIG_HPP
|
|
|
|
#define LIBLLARP_CONFIG_HPP
|
2017-11-28 14:05:31 +00:00
|
|
|
#include <map>
|
|
|
|
#include <string>
|
|
|
|
|
2018-01-25 16:24:33 +00:00
|
|
|
#include <llarp/config.h>
|
2017-11-28 14:05:31 +00:00
|
|
|
|
2018-01-25 16:24:33 +00:00
|
|
|
namespace llarp
|
2017-11-28 14:05:31 +00:00
|
|
|
{
|
|
|
|
struct Config
|
|
|
|
{
|
|
|
|
typedef std::map<std::string, std::string> section_t;
|
|
|
|
|
|
|
|
section_t router;
|
|
|
|
section_t network;
|
|
|
|
section_t netdb;
|
2018-01-19 16:51:27 +00:00
|
|
|
section_t links;
|
2017-11-28 14:05:31 +00:00
|
|
|
|
|
|
|
bool Load(const char * fname);
|
|
|
|
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
extern "C" {
|
2018-01-25 16:24:33 +00:00
|
|
|
struct llarp_config
|
2017-11-28 14:05:31 +00:00
|
|
|
{
|
2018-01-25 16:24:33 +00:00
|
|
|
llarp::Config impl;
|
2017-11-28 14:05:31 +00:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|