theConfig 10.0 NHI1 - theKernel - theLink - theConfig - theSq3Lite - theCompiler - theBrain - theGuard
c - tcl - cs - py - rb - jv - cc
Loading...
Searching...
No Matches
LcSettingC_Lookup_C_API

LcSettingC - various functions to lookup a settingMore...

+ Collaboration diagram for LcSettingC_Lookup_C_API:

Functions

MK_BFL LcSettingLookupAll (LC_CFSN setting)
 addon - read an entire configuration below setting into MkBufferListC
 
static LC_CFS LcSettingLookup (LC_CFS setting, MK_STRN path)
 This function locates a setting by a path path relative to the setting setting
 
static enum MkErrorE LcSettingLookupBool (LC_CFSN setting, MK_STRN name, MK_BOOL *value_out)
 These functions look up the value of the child setting named name of the setting setting
 
static enum MkErrorE LcSettingLookupFloat (LC_CFSN setting, MK_STRN name, MK_DBL *value_out)
 These functions look up the value of the child setting named name of the setting setting
 
static enum MkErrorE LcSettingLookupInt (LC_CFSN setting, MK_STRN name, MK_I32 *value_out)
 These functions look up the value of the child setting named name of the setting setting
 
static enum MkErrorE LcSettingLookupInt64 (LC_CFSN setting, MK_STRN name, MK_I64 *value_out)
 These functions look up the value of the child setting named name of the setting setting
 
static enum MkErrorE LcSettingLookupString (LC_CFSN setting, MK_STRN name, MK_STRN *value_out)
 These functions look up the value of the child setting named name of the setting setting
 

LcSettingC - LcSettingC_Lookup_C_API - function

LC_CFS LcSettingLookupP (LC_CFS setting, MK_STRN path)
 Non-inline replacement for LcSettingLookup
 
enum MkErrorE LcSettingLookupBoolP (LC_CFSN setting, MK_STRN name, MK_BOOL *value_out)
 Non-inline replacement for LcSettingLookupBool
 
enum MkErrorE LcSettingLookupFloatP (LC_CFSN setting, MK_STRN name, MK_DBL *value_out)
 Non-inline replacement for LcSettingLookupFloat
 
enum MkErrorE LcSettingLookupIntP (LC_CFSN setting, MK_STRN name, MK_I32 *value_out)
 Non-inline replacement for LcSettingLookupInt
 
enum MkErrorE LcSettingLookupInt64P (LC_CFSN setting, MK_STRN name, MK_I64 *value_out)
 Non-inline replacement for LcSettingLookupInt64
 
enum MkErrorE LcSettingLookupStringP (LC_CFSN setting, MK_STRN name, MK_STRN *value_out)
 Non-inline replacement for LcSettingLookupString
 

LcSettingC - LcSettingC_Lookup_C_API - overload

#define LcSettingLookupBool_E(...)
 
#define LcSettingLookupBool_C(...)
 
#define LcSettingLookupBool_e(...)
 
#define LcSettingLookupFloat_E(...)
 
#define LcSettingLookupFloat_C(...)
 
#define LcSettingLookupFloat_e(...)
 
#define LcSettingLookupInt_E(...)
 
#define LcSettingLookupInt_C(...)
 
#define LcSettingLookupInt_e(...)
 
#define LcSettingLookupInt64_E(...)
 
#define LcSettingLookupInt64_C(...)
 
#define LcSettingLookupInt64_e(...)
 
#define LcSettingLookupString_E(...)
 
#define LcSettingLookupString_C(...)
 
#define LcSettingLookupString_e(...)
 

Detailed Description

LcSettingC - various functions to lookup a setting

Macro Definition Documentation

◆ LcSettingLookupBool_C

#define LcSettingLookupBool_C ( ...)
Value:
if (MkErrorCheckI(LcSettingLookupBool(__VA_ARGS__)))
static enum MkErrorE LcSettingLookupBool(LC_CFSN setting, MK_STRN name, MK_BOOL *value_out)
These functions look up the value of the child setting named name of the setting setting …

Definition at line 190 of file config_overload_lc.h.

◆ LcSettingLookupBool_E

#define LcSettingLookupBool_E ( ...)
Value:
MkErrorCheck(LcSettingLookupBool(__VA_ARGS__))

Definition at line 189 of file config_overload_lc.h.

◆ LcSettingLookupBool_e

#define LcSettingLookupBool_e ( ...)
Value:
MK_EMBEDDED(MK_BOOL,LcSettingLookupBool,__VA_ARGS__)
bool MK_BOOL

Definition at line 191 of file config_overload_lc.h.

◆ LcSettingLookupFloat_C

#define LcSettingLookupFloat_C ( ...)
Value:
if (MkErrorCheckI(LcSettingLookupFloat(__VA_ARGS__)))
static enum MkErrorE LcSettingLookupFloat(LC_CFSN setting, MK_STRN name, MK_DBL *value_out)
These functions look up the value of the child setting named name of the setting setting …

Definition at line 193 of file config_overload_lc.h.

◆ LcSettingLookupFloat_E

#define LcSettingLookupFloat_E ( ...)
Value:
MkErrorCheck(LcSettingLookupFloat(__VA_ARGS__))

Definition at line 192 of file config_overload_lc.h.

◆ LcSettingLookupFloat_e

#define LcSettingLookupFloat_e ( ...)
Value:
MK_EMBEDDED(MK_DBL,LcSettingLookupFloat,__VA_ARGS__)
double MK_DBL

Definition at line 194 of file config_overload_lc.h.

◆ LcSettingLookupInt64_C

#define LcSettingLookupInt64_C ( ...)
Value:
if (MkErrorCheckI(LcSettingLookupInt64(__VA_ARGS__)))
static enum MkErrorE LcSettingLookupInt64(LC_CFSN setting, MK_STRN name, MK_I64 *value_out)
These functions look up the value of the child setting named name of the setting setting …

Definition at line 199 of file config_overload_lc.h.

◆ LcSettingLookupInt64_E

#define LcSettingLookupInt64_E ( ...)
Value:
MkErrorCheck(LcSettingLookupInt64(__VA_ARGS__))

Definition at line 198 of file config_overload_lc.h.

◆ LcSettingLookupInt64_e

#define LcSettingLookupInt64_e ( ...)
Value:
MK_EMBEDDED(MK_I64,LcSettingLookupInt64,__VA_ARGS__)
signed long long MK_I64

Definition at line 200 of file config_overload_lc.h.

◆ LcSettingLookupInt_C

#define LcSettingLookupInt_C ( ...)
Value:
if (MkErrorCheckI(LcSettingLookupInt(__VA_ARGS__)))
static enum MkErrorE LcSettingLookupInt(LC_CFSN setting, MK_STRN name, MK_I32 *value_out)
These functions look up the value of the child setting named name of the setting setting …

Definition at line 196 of file config_overload_lc.h.

◆ LcSettingLookupInt_E

#define LcSettingLookupInt_E ( ...)
Value:
MkErrorCheck(LcSettingLookupInt(__VA_ARGS__))

Definition at line 195 of file config_overload_lc.h.

◆ LcSettingLookupInt_e

#define LcSettingLookupInt_e ( ...)
Value:
MK_EMBEDDED(MK_I32,LcSettingLookupInt,__VA_ARGS__)
signed int MK_I32

Definition at line 197 of file config_overload_lc.h.

◆ LcSettingLookupString_C

#define LcSettingLookupString_C ( ...)
Value:
if (MkErrorCheckI(LcSettingLookupString(__VA_ARGS__)))
static enum MkErrorE LcSettingLookupString(LC_CFSN setting, MK_STRN name, MK_STRN *value_out)
These functions look up the value of the child setting named name of the setting setting …

Definition at line 202 of file config_overload_lc.h.

◆ LcSettingLookupString_E

#define LcSettingLookupString_E ( ...)
Value:
MkErrorCheck(LcSettingLookupString(__VA_ARGS__))

Definition at line 201 of file config_overload_lc.h.

◆ LcSettingLookupString_e

#define LcSettingLookupString_e ( ...)
Value:
MK_EMBEDDED(MK_STRN,LcSettingLookupString,__VA_ARGS__)
const MK_STRB * MK_STRN

Definition at line 203 of file config_overload_lc.h.

Function Documentation

◆ LcSettingLookup()

static LC_CFS LcSettingLookup ( LC_CFS setting,
MK_STRN path )
inlinestatic

This function locates a setting by a path path relative to the setting setting

It returns a pointer to the LcSettingC structure on success, or NULL if the setting was not found.

Definition at line 223 of file LcSettingC_lc.h.

223 {
224 LC_INSTANCE_HDL(setting);
225 return LcSettingC_ObjNew(config_setting_lookup(setting->nat, path));
226 }
#define LC_INSTANCE_HDL(x)
static MK_ARTIFICIAL LC_CFS LcSettingC_ObjNew(config_setting_t *hdl)
return Programming-Language-Micro-Kernel (PLMK) instance from native hdl …
LIBCONFIG_API config_setting_t * config_setting_lookup(config_setting_t *setting, const char *path)
config_setting_t * nat
internal - link between LcSettingS and native library
+ Here is the caller graph for this function:

◆ LcSettingLookupAll()

MK_BFL LcSettingLookupAll ( LC_CFSN setting)

addon - read an entire configuration below setting into MkBufferListC

Returns
instand of MkBufferListC owned by MkBufferListC [$setting LookupAll]
+ Here is the caller graph for this function:

◆ LcSettingLookupBool()

static enum MkErrorE LcSettingLookupBool ( LC_CFSN setting,
MK_STRN name,
MK_BOOL * value_out )
inlinestatic

These functions look up the value of the child setting named name of the setting setting

They store the value at value and return CONFIG_TRUE on success. If the setting was not found or if the type of the value did not match the type requested, they leave the data pointed to by value unmodified and return CONFIG_FALSE.

Storage for the string returned by SettingLookupString is managed by the library and released automatically when the setting is destroyed or when the setting's value is changed; the string must not be freed by the caller.

See also
SettingLookupFloat, SettingLookupInt, SettingLookupInt64, SettingLookupString

Definition at line 231 of file LcSettingC_lc.h.

231 {
232 LC_INSTANCE_HDL(setting);
233 MK_I32 value_out_val = 0;
234 enum LcErrorE errVal = (enum LcErrorE)config_setting_lookup_bool(setting->nat, name, &value_out_val);
235 *value_out = (MK_BOOL)(value_out_val);
236 LcErrorE_Check(setting, errVal);
237 return MK_OK;
238 error:
239 return MK_ERROR;
240 }
LcErrorE
Signals an error and is used as the return value of a function …
Definition LcEnum_lc.h:191
#define LcErrorE_Check(lc_hdl, PROC)
check on a tcllcconfig error and convert into a tcllcconfig error …
MK_ERROR
MK_OK
LIBCONFIG_API int config_setting_lookup_bool(const config_setting_t *setting, const char *name, int *value)
+ Here is the caller graph for this function:

◆ LcSettingLookupBoolP()

enum MkErrorE LcSettingLookupBoolP ( LC_CFSN setting,
MK_STRN name,
MK_BOOL * value_out )

Non-inline replacement for LcSettingLookupBool

◆ LcSettingLookupFloat()

static enum MkErrorE LcSettingLookupFloat ( LC_CFSN setting,
MK_STRN name,
MK_DBL * value_out )
inlinestatic

These functions look up the value of the child setting named name of the setting setting

They store the value at value and return CONFIG_TRUE on success. If the setting was not found or if the type of the value did not match the type requested, they leave the data pointed to by value unmodified and return CONFIG_FALSE.

Storage for the string returned by SettingLookupString is managed by the library and released automatically when the setting is destroyed or when the setting's value is changed; the string must not be freed by the caller.

See also
SettingLookupBool, SettingLookupInt, SettingLookupInt64, SettingLookupString

Definition at line 243 of file LcSettingC_lc.h.

243 {
244 LC_INSTANCE_HDL(setting);
245 enum LcErrorE errVal = (enum LcErrorE)config_setting_lookup_float(setting->nat, name, value_out);
246 LcErrorE_Check(setting, errVal);
247 return MK_OK;
248 error:
249 return MK_ERROR;
250 }
LIBCONFIG_API int config_setting_lookup_float(const config_setting_t *setting, const char *name, double *value)
+ Here is the caller graph for this function:

◆ LcSettingLookupFloatP()

enum MkErrorE LcSettingLookupFloatP ( LC_CFSN setting,
MK_STRN name,
MK_DBL * value_out )

Non-inline replacement for LcSettingLookupFloat

◆ LcSettingLookupInt()

static enum MkErrorE LcSettingLookupInt ( LC_CFSN setting,
MK_STRN name,
MK_I32 * value_out )
inlinestatic

These functions look up the value of the child setting named name of the setting setting

They store the value at value and return CONFIG_TRUE on success. If the setting was not found or if the type of the value did not match the type requested, they leave the data pointed to by value unmodified and return CONFIG_FALSE.

Storage for the string returned by SettingLookupString is managed by the library and released automatically when the setting is destroyed or when the setting's value is changed; the string must not be freed by the caller.

See also
SettingLookupBool, SettingLookupFloat, SettingLookupInt64, SettingLookupString

Definition at line 253 of file LcSettingC_lc.h.

253 {
254 LC_INSTANCE_HDL(setting);
255 enum LcErrorE errVal = (enum LcErrorE)config_setting_lookup_int(setting->nat, name, value_out);
256 LcErrorE_Check(setting, errVal);
257 return MK_OK;
258 error:
259 return MK_ERROR;
260 }
LIBCONFIG_API int config_setting_lookup_int(const config_setting_t *setting, const char *name, int *value)
+ Here is the caller graph for this function:

◆ LcSettingLookupInt64()

static enum MkErrorE LcSettingLookupInt64 ( LC_CFSN setting,
MK_STRN name,
MK_I64 * value_out )
inlinestatic

These functions look up the value of the child setting named name of the setting setting

They store the value at value and return CONFIG_TRUE on success. If the setting was not found or if the type of the value did not match the type requested, they leave the data pointed to by value unmodified and return CONFIG_FALSE.

Storage for the string returned by SettingLookupString is managed by the library and released automatically when the setting is destroyed or when the setting's value is changed; the string must not be freed by the caller.

See also
SettingLookupBool, SettingLookupFloat, SettingLookupInt, SettingLookupString

Definition at line 263 of file LcSettingC_lc.h.

263 {
264 LC_INSTANCE_HDL(setting);
265 enum LcErrorE errVal = (enum LcErrorE)config_setting_lookup_int64(setting->nat, name, value_out);
266 LcErrorE_Check(setting, errVal);
267 return MK_OK;
268 error:
269 return MK_ERROR;
270 }
LIBCONFIG_API int config_setting_lookup_int64(const config_setting_t *setting, const char *name, long long *value)
+ Here is the caller graph for this function:

◆ LcSettingLookupInt64P()

enum MkErrorE LcSettingLookupInt64P ( LC_CFSN setting,
MK_STRN name,
MK_I64 * value_out )

Non-inline replacement for LcSettingLookupInt64

◆ LcSettingLookupIntP()

enum MkErrorE LcSettingLookupIntP ( LC_CFSN setting,
MK_STRN name,
MK_I32 * value_out )

Non-inline replacement for LcSettingLookupInt

◆ LcSettingLookupP()

LC_CFS LcSettingLookupP ( LC_CFS setting,
MK_STRN path )

Non-inline replacement for LcSettingLookup

◆ LcSettingLookupString()

static enum MkErrorE LcSettingLookupString ( LC_CFSN setting,
MK_STRN name,
MK_STRN * value_out )
inlinestatic

These functions look up the value of the child setting named name of the setting setting

They store the value at value and return CONFIG_TRUE on success. If the setting was not found or if the type of the value did not match the type requested, they leave the data pointed to by value unmodified and return CONFIG_FALSE.

Storage for the string returned by SettingLookupString is managed by the library and released automatically when the setting is destroyed or when the setting's value is changed; the string must not be freed by the caller.

See also
SettingLookupBool, SettingLookupFloat, SettingLookupInt, SettingLookupInt64

Definition at line 273 of file LcSettingC_lc.h.

273 {
274 LC_INSTANCE_HDL(setting);
275 enum LcErrorE errVal = (enum LcErrorE)config_setting_lookup_string(setting->nat, name, value_out);
276 LcErrorE_Check(setting, errVal);
277 return MK_OK;
278 error:
279 return MK_ERROR;
280 }
LIBCONFIG_API int config_setting_lookup_string(const config_setting_t *setting, const char *name, const char **value)
+ Here is the caller graph for this function:

◆ LcSettingLookupStringP()

enum MkErrorE LcSettingLookupStringP ( LC_CFSN setting,
MK_STRN name,
MK_STRN * value_out )

Non-inline replacement for LcSettingLookupString