1 |
#ifndef SUDOBOT_ENV_ENV_H |
2 |
#define SUDOBOT_ENV_ENV_H |
3 |
|
4 |
struct envtable; |
5 |
|
6 |
typedef struct env { |
7 |
char *filepath; |
8 |
struct envtable *table; |
9 |
char *error; |
10 |
size_t index; |
11 |
char *contents; |
12 |
size_t length; |
13 |
size_t current_line; |
14 |
} env_t; |
15 |
|
16 |
env_t *env_init(); |
17 |
bool env_load(env_t *env); |
18 |
void env_free(env_t *env); |
19 |
const char *env_get_local(env_t *env, const char *restrict name); |
20 |
const char *env_get(env_t *env, const char *restrict name); |
21 |
|
22 |
#endif /* SUDOBOT_ENV_ENV_H */ |