rlib
Convenience library for useful things
Loading...
Searching...
No Matches
renv.h
Go to the documentation of this file.
1/* RLIB - Convenience library for useful things
2 * Copyright (C) 2015 Haakon Sporsheim <haakon.sporsheim@gmail.com>
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 3.0 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library.
16 * See the COPYING file at the root of the source repository.
17 */
18#ifndef __R_ENV_H__
19#define __R_ENV_H__
20
21#if !defined(__RLIB_H_INCLUDE_GUARD__) && !defined(RLIB_COMPILATION)
22#error "#include <rlib.h> only please."
23#endif
24
31#include <rlib/rtypes.h>
32
34
53R_API const rchar * r_getenv (const rchar * key);
62R_API rboolean r_setenv (const rchar * key, const rchar * val, rboolean always);
65
66R_END_DECLS
67
70#endif /* __R_ENV_H__ */
rboolean r_setenv(const rchar *key, const rchar *val, rboolean always)
Set key to val in the process environment.
rboolean r_unsetenv(const rchar *key)
Remove key from the process environment.
const rchar * r_getenv(const rchar *key)
Look up key in the process environment.
#define R_API
Public-API decoration: resolves to R_API_EXPORT while building rlib and R_API_IMPORT for consumers.
Definition rmacros.h:115
#define R_BEGIN_DECLS
Open an extern "C" block under C++ (no-op in C).
Definition rmacros.h:196
char rchar
Default character type (char).
Definition rtypes.h:137
int rboolean
Boolean type (typedef'd to int).
Definition rtypes.h:59
Foundational type aliases used by every rlib header.