31 #define CRINIT_GLOBOPT_DEBUG debug
32 #define CRINIT_GLOBOPT_USE_SYSLOG useSyslog
33 #define CRINIT_GLOBOPT_USE_ELOS useElos
34 #define CRINIT_GLOBOPT_ELOS_PORT elosPort
35 #define CRINIT_GLOBOPT_ELOS_SERVER elosServer
36 #define CRINIT_GLOBOPT_INCLDIR inclDir
37 #define CRINIT_GLOBOPT_INCL_SUFFIX inclSuffix
38 #define CRINIT_GLOBOPT_SHDGRACEP shdGraceP
39 #define CRINIT_GLOBOPT_ENV globEnv
40 #define CRINIT_GLOBOPT_FILTERS globFilters
61 #define crinitGlobOptGet(globOptMember, retPtr) \
62 _Generic((crinitGenericGlobOptHelper.globOptMember), \
63 char * : crinitGlobOptGetString, \
64 bool : crinitGlobOptGetBoolean, \
65 int : crinitGlobOptGetInteger, \
66 unsigned long long : crinitGlobOptGetUnsignedLL, \
67 crinitEnvSet_t : crinitGlobOptGetEnvSet) \
68 ((offsetof(crinitGlobOptStore_t, globOptMember)), (retPtr))
80 #define crinitGlobOptSet(globOptMember, val) \
81 _Generic((crinitGenericGlobOptHelper.globOptMember), \
82 char * : crinitGlobOptSetString, \
83 const char * : crinitGlobOptSetString, \
84 bool : crinitGlobOptSetBoolean, \
85 int : crinitGlobOptSetInteger, \
86 unsigned long long : crinitGlobOptSetUnsignedLL, \
87 crinitEnvSet_t : crinitGlobOptSetEnvSet) \
88 ((offsetof(crinitGlobOptStore_t, globOptMember)), (val))
Header defining data types and functions to work with sets of environment variables.
int crinitGlobOptGetBoolean(size_t memberOffset, bool *val)
Definition: globopt.c:136
int crinitGlobOptGetInteger(size_t memberOffset, int *val)
Definition: globopt.c:158
int crinitGlobOptRemit(void)
Definition: globopt.c:238
int crinitGlobOptSetString(size_t memberOffset, const char *val)
Definition: globopt.c:84
crinitGlobOptStore_t * crinitGlobOptBorrow(void)
Definition: globopt.c:230
struct crinitGlobOptStore_t crinitGlobOptStore_t
int crinitGlobOptInitDefault(void)
Definition: globopt.c:40
int crinitGlobOptSetEnvSet(size_t memberOffset, const crinitEnvSet_t *val)
Definition: globopt.c:191
int crinitGlobOptGetString(size_t memberOffset, char **val)
Definition: globopt.c:103
int crinitGlobOptGetEnvSet(size_t memberOffset, crinitEnvSet_t *val)
Definition: globopt.c:213
int crinitGlobOptSetBoolean(size_t memberOffset, bool val)
Definition: globopt.c:125
int crinitGlobOptGetUnsignedLL(size_t memberOffset, unsigned long long *val)
Definition: globopt.c:180
void crinitGlobOptDestroy(void)
Definition: globopt.c:249
int crinitGlobOptSetInteger(size_t memberOffset, int val)
Definition: globopt.c:147
static crinitGlobOptStore_t crinitGenericGlobOptHelper __attribute__((unused))
int crinitGlobOptSetUnsignedLL(size_t memberOffset, unsigned long long val)
Definition: globopt.c:169
int elosPort
Value for the ELOS_PORT global option.
Definition: globopt.h:22
crinitEnvSet_t globFilters
Storage for global task filter variables.
Definition: globopt.h:28
char * inclDir
Value for the INCLUDEDIR global option.
Definition: globopt.h:24
unsigned long long shdGraceP
Value for the SHUTDOWN_GRACE_PERIOD_US global option.
Definition: globopt.h:26
char * elosServer
Value for the ELOS_SERVER global option.
Definition: globopt.h:23
bool debug
Value for the DEBUG global option.
Definition: globopt.h:19
bool useElos
Value for the USE_ELOS global option.
Definition: globopt.h:21
crinitEnvSet_t globEnv
Storage for global task environment variables.
Definition: globopt.h:27
char * inclSuffix
Value for the INCLUDE_SUFFIX global option.
Definition: globopt.h:25
bool useSyslog
Value for the USE_SYSLOG global option.
Definition: globopt.h:20