10#define META_FILE_NAME "LcConfigC_jv.c"
12#include "jni_h/jvlcconfig_LcConfigC.h"
13#include "LibLcConfig_private_jv.h"
27 JNIEnv *env = (JNIEnv*) envP;
28 return (*env)->NewObject(env, NS(Class_LcConfigC), NS(MID_LcConfigC_INIT), (jlong) obj, JNI_TRUE);
132 jobject __retVal__S = MK(pGetEnumFromString)(env,LC(Class_LcErrorTypeE),
"Ljvlcconfig/LcErrorTypeE;",
LcErrorTypeE_ToString(__retVal__L));
153 jobject __retVal__S = MK(pGetEnumFromString)(env,LC(Class_LcConfigFormatE),
"Ljvlcconfig/LcConfigFormatE;",
LcConfigFormatE_ToString(__retVal__L));
165 jshort __retVal__S = __retVal__L;
177 jstring __retVal__S = JC2O(env,__retVal__L);
188 enum LcConfigOptionsEF option_e = MK(pGetEnumFromObj)(env, NS(Class_LcConfigOptionsEF), option);
191 jboolean __retVal__S = __retVal__L;
203 jobject __retVal__S = MK(pGetEnumFlagFromInt)(env,LC(Class_LcConfigOptionsEF),__retVal__L);
215 jshort __retVal__S = __retVal__L;
235 MK_STRN path_ptr = (path?(*env)->GetStringUTFChars(env,path,NULL):NULL);
239 if (path_ptr) (*env)->ReleaseStringUTFChars(env,path,path_ptr);
253 MK_STRN path_ptr = (path?(*env)->GetStringUTFChars(env,path,NULL):NULL);
256 MkErrorC_Check(hdl, errVal)
257 jboolean __retVal__S = value_out;
258 if (path_ptr) (*env)->ReleaseStringUTFChars(env,path,path_ptr);
270 MK_STRN path_ptr = (path?(*env)->GetStringUTFChars(env,path,NULL):NULL);
273 MkErrorC_Check(hdl, errVal)
274 jdouble __retVal__S = value_out;
275 if (path_ptr) (*env)->ReleaseStringUTFChars(env,path,path_ptr);
287 MK_STRN path_ptr = (path?(*env)->GetStringUTFChars(env,path,NULL):NULL);
290 MkErrorC_Check(hdl, errVal)
291 jint __retVal__S = value_out;
292 if (path_ptr) (*env)->ReleaseStringUTFChars(env,path,path_ptr);
304 MK_STRN path_ptr = (path?(*env)->GetStringUTFChars(env,path,NULL):NULL);
307 MkErrorC_Check(hdl, errVal)
308 jlong __retVal__S = value_out;
309 if (path_ptr) (*env)->ReleaseStringUTFChars(env,path,path_ptr);
321 MK_STRN path_ptr = (path?(*env)->GetStringUTFChars(env,path,NULL):NULL);
324 MkErrorC_Check(hdl, errVal)
325 jstring __retVal__S = JC2O(env,value_out);
326 if (path_ptr) (*env)->ReleaseStringUTFChars(env,path,path_ptr);
372 if (callfunc == NULL) {
373 (*env)->CallStaticVoidMethod(env,MK(Class_MkKernel),MK(MID_MkKernel_getCallerStack));
375 if (callfunc == NULL) {callfunc = MK(pGetCallerProc)(env);}
377 MK_STRN callfunc_ptr = (callfunc?(*env)->GetStringUTFChars(env,callfunc,NULL):NULL);
379 LcConfigLog(hdl, fmtobj_hdl, debug, callfunc_ptr, lvl);
380 if (callfunc_ptr) (*env)->ReleaseStringUTFChars(env,callfunc,callfunc_ptr);
390 MK_STRN filename_ptr = (filename?(*env)->GetStringUTFChars(env,filename,NULL):NULL);
393 MkErrorC_Check(hdl, errVal)
394 if (filename_ptr) (*env)->ReleaseStringUTFChars(env,filename,filename_ptr);
404 MK_STRN str_ptr = (str?(*env)->GetStringUTFChars(env,str,NULL):NULL);
407 MkErrorC_Check(hdl, errVal)
408 if (str_ptr) (*env)->ReleaseStringUTFChars(env,str,str_ptr);
418 MK_STRN filename_ptr = (filename?(*env)->GetStringUTFChars(env,filename,NULL):NULL);
421 MkErrorC_Check(hdl, errVal)
422 if (filename_ptr) (*env)->ReleaseStringUTFChars(env,filename,filename_ptr);
436 MkErrorC_Check(hdl, errVal)
437 jstring __retVal__S = JC2O(env,val_out);
457 enum LcConfigFormatE format_e = MK(pGetEnumFromObj)(env, NS(Class_LcConfigFormatE), format);
479 MK_STRN include_dir_ptr = (include_dir?(*env)->GetStringUTFChars(env,include_dir,NULL):NULL);
482 if (include_dir_ptr) (*env)->ReleaseStringUTFChars(env,include_dir,include_dir_ptr);
493 LC_CBP fConfigIncludeData_ptr = MK(ProcCreate)(
MK_RT_CALL env, fConfigIncludeData, NULL, NS(MID_fConfigIncludeData),
true);
495 if (fConfigIncludeData_ptr == NULL) fConfigIncludeCall = NULL;
497 MkErrorC_Check(hdl, errVal)
507 enum LcConfigOptionsEF option_e = MK(pGetEnumFromObj)(env, NS(Class_LcConfigOptionsEF), option);
519 enum LcConfigOptionsEF options_e = MK(pGetEnumFromObj)(env, NS(Class_LcConfigOptionsEF), options);
532 LC_CBP fSettingDeleteData_ptr = MK(ProcCreate)(
MK_RT_CALL env, fSettingDeleteData, NULL, NS(MID_fSettingDeleteData),
true);
534 if (fSettingDeleteData_ptr == NULL) fSettingDeleteCall = NULL;
536 MkErrorC_Check(hdl, errVal)
564 if (__retVal__L == NULL) {
565 (*env)->ThrowNew(env, MK(Class_MkInitError),
"LcConfigC.CTOR");
568 jlong __retVal__S = (jlong)__retVal__L;
578 if (__retVal__L == NULL) {
579 (*env)->ThrowNew(env, MK(Class_MkInitError),
"LcConfigC.Create");
610 jstring fConfigIncludeDataString
615 jmethodID meth = (*env)->GetStaticMethodID(env,MK(Class_MkKernel),
"resolveCallback",
616 "(Ljava/lang/Class;Ljava/lang/Class;Ljava/lang/String;)Ljava/lang/Class;");
618 jclass fConfigIncludeData = (*env)->CallStaticObjectMethod(env, MK(Class_MkKernel), meth, searchClass,
619 LC(Class_LcConfigIncludeIF), fConfigIncludeDataString);
621 LC_CBP fConfigIncludeData_ptr = MK(ProcCreate)(
MK_RT_CALL_NULL env, fConfigIncludeData, NULL, NS(MID_fConfigIncludeData),
true);
624 MkErrorC_Check(hdl, errVal)
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_SetIncludeFunc__Ljava_C_langlass_2Ljava_lang_String_2(JNIEnv *env, jobject self, jclass searchClass, jstring fConfigIncludeDataString)
Java: cfg.SetIncludeFunc(?LcConfigIncludeIF fConfigIncludeData = null?) → C-API set the __parse...
enum MkErrorE(* LcSettingDeleteCallF)(LcSettingDeleteCallF_ARGS)
enum MkErrorE(* LcConfigIncludeCallF)(LcConfigIncludeCallF_ARGS)
static MK_ARTIFICIAL LC_CFG LcConfigC_ObjNew(config_t *hdl)
return Programming-Language-Micro-Kernel (PLMK) instance from native hdl …
const struct LcConfigS * LC_CFGN
class-shortcut for const struct LcConfigS *, all const shortcut using the XX_YYYC syntax (only for pu...
struct LcConfigS * LC_CFG
class-shortcut for struct LcConfigS *, all shortcut using the XX_YYY syntax (only for public API) …
#define LcConfigInstances()
static LC_CFG LcConfigPrev(LC_CFG const cfg)
get previous instance from linked-list of LcConfigS type
static LC_CFG LcConfigC_ObjCreate(config_t *hdl)
return Programming-Language-Micro-Kernel (PLMK) instance from native hdl …
static LC_CFG LcConfigNext(LC_CFG const cfg)
get next instance from linked-list of LcConfigS type
static LC_CFG LcConfigGetNull(void)
Null-Slot - return a LcConfigC typed NULL instance …
#define LcConfigHandleResolve(...)
#define LcConfigC_X2obj(x)
__thread MK_TYP LcConfigC_TT
class as MkTypeDefS-class-type …
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_Next(JNIEnv *env, jobject self)
Java: LcConfigC cfg.Next() → C-API get next instance from linked-list of LcConfigS type
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_Prev(JNIEnv *env, jobject self)
Java: LcConfigC cfg.Prev() → C-API get previous instance from linked-list of LcConfigS type
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_GetNull(JNIEnv *env, jclass class)
Java: [static] LcConfigC LcConfigC.GetNull() → C-API Null-Slot - return a LcConfigC typed NULL i...
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_Instances(JNIEnv *env, jclass class)
Java: [static] LcConfigC LcConfigC.Instances() → C-API get head-instance from linked-list of LcC...
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_HandleResolve(JNIEnv *env, jclass class, jint netHdl)
Java: [static] LcConfigC LcConfigC.HandleResolve(int netHdl) → C-API Handle-Resolve-Slot - retur...
static enum LcErrorTypeE LcConfigErrorType(LC_CFGN config)
This function, which is implemented as a macro, returns the type of error that occurred during the la...
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_ErrorType(JNIEnv *env, jobject self)
Java: LcErrorTypeE config.ErrorType() → C-API This function, which is implemented as a macro,...
static enum LcConfigFormatE LcConfigGetDefaultFormat(LC_CFGN config)
These functions, which are implemented as macros, get and set the default external format for setting...
static MK_I16 LcConfigGetTabWidth(LC_CFGN config)
These functions, which are implemented as macros, get and set the tab width for the configuration con...
static MK_BOOL LcConfigGetOption(LC_CFGN config, enum LcConfigOptionsEF option)
Since v1.7 These functions get and set the given option of the configuration config …
static MK_I16 LcConfigGetFloatPrecision(LC_CFGN config)
Since v1.6 These functions get and set the number of decimal digits to output after the radix charact...
static enum LcConfigOptionsEF LcConfigGetOptions(LC_CFGN config)
These functions get and set the options for the configuration config …
static MK_STRN LcConfigGetIncludeDir(LC_CFGN config)
ConfigSetIncludeDir specifies the include directory, include_dir, relative to which the files specifi...
JNIEXPORT jstring JNICALL Java_jvlcconfig_LcConfigC_GetIncludeDir(JNIEnv *env, jobject self)
Java: String config.GetIncludeDir() → C-API ConfigSetIncludeDir specifies the include directory...
JNIEXPORT jboolean JNICALL Java_jvlcconfig_LcConfigC_GetOption(JNIEnv *env, jobject self, jobject option)
Java: boolean config.GetOption(LcConfigOptionsEF option) → C-API Since v1.7 These functions get...
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_GetOptions(JNIEnv *env, jobject self)
Java: LcConfigOptionsEF config.GetOptions() → C-API These functions get and set the options for...
JNIEXPORT jshort JNICALL Java_jvlcconfig_LcConfigC_GetTabWidth(JNIEnv *env, jobject self)
Java: short config.GetTabWidth() → C-API These functions, which are implemented as macros,...
JNIEXPORT jshort JNICALL Java_jvlcconfig_LcConfigC_GetFloatPrecision(JNIEnv *env, jobject self)
Java: short config.GetFloatPrecision() → C-API Since v1.6 These functions get and set the numbe...
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_GetDefaultFormat(JNIEnv *env, jobject self)
Java: LcConfigFormatE config.GetDefaultFormat() → C-API These functions, which are implemented ...
static enum MkErrorE LcConfigLookupFloat(LC_CFGN config, MK_STRN path, MK_DBL *value_out)
These functions look up the value of the setting in the configuration config specified by the path pa...
static enum MkErrorE LcConfigLookupBool(LC_CFGN config, MK_STRN path, MK_BOOL *value_out)
These functions look up the value of the setting in the configuration config specified by the path pa...
static enum MkErrorE LcConfigLookupString(LC_CFGN config, MK_STRN path, MK_STRN *value_out)
These functions look up the value of the setting in the configuration config specified by the path pa...
static enum MkErrorE LcConfigLookupInt(LC_CFGN config, MK_STRN path, MK_I32 *value_out)
These functions look up the value of the setting in the configuration config specified by the path pa...
static enum MkErrorE LcConfigLookupInt64(LC_CFGN config, MK_STRN path, MK_I64 *value_out)
These functions look up the value of the setting in the configuration config specified by the path pa...
static LC_CFS LcConfigLookup(LC_CFGN config, MK_STRN path)
This function locates the setting in the configuration config specified by the path path …
JNIEXPORT jint JNICALL Java_jvlcconfig_LcConfigC_LookupInt(JNIEnv *env, jobject self, jstring path)
Java: int config.LookupInt(String path) → C-API These functions look up the value of the settin...
JNIEXPORT jdouble JNICALL Java_jvlcconfig_LcConfigC_LookupFloat(JNIEnv *env, jobject self, jstring path)
Java: double config.LookupFloat(String path) → C-API These functions look up the value of the s...
JNIEXPORT jstring JNICALL Java_jvlcconfig_LcConfigC_LookupString(JNIEnv *env, jobject self, jstring path)
Java: String config.LookupString(String path) → C-API These functions look up the value of the ...
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_Lookup(JNIEnv *env, jobject self, jstring path)
Java: LcSettingC config.Lookup(String path) → C-API This function locates the setting in the co...
JNIEXPORT jlong JNICALL Java_jvlcconfig_LcConfigC_LookupInt64(JNIEnv *env, jobject self, jstring path)
Java: long config.LookupInt64(String path) → C-API These functions look up the value of the set...
JNIEXPORT jboolean JNICALL Java_jvlcconfig_LcConfigC_LookupBool(JNIEnv *env, jobject self, jstring path)
Java: boolean config.LookupBool(String path) → C-API These functions look up the value of the s...
static enum MkErrorE LcConfigWriteFile(LC_CFG config, MK_STRN filename)
This function writes the configuration config to the file named filename …
#define LcConfigWriteString(...)
static LC_CFS LcConfigRootSetting(LC_CFGN config)
This function, which is implemented as a macro, returns the root setting for the configuration config...
static void LcConfigClear(LC_CFG config)
Since v1.7 This function clears the configuration config …
static enum MkErrorE LcConfigReadFile(LC_CFG config, MK_STRN filename)
This function reads and parses a configuration from the file named filename into the configuration ob...
static enum MkErrorE LcConfigReadString(LC_CFG config, MK_STRN str)
This function reads and parses a configuration from the string str into the configuration object conf...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_ReadString(JNIEnv *env, jobject self, jstring str)
Java: config.ReadString(String str) → C-API This function reads and parses a configuration from...
JNIEXPORT jstring JNICALL Java_jvlcconfig_LcConfigC_WriteString(JNIEnv *env, jobject self)
Java: String cfg.WriteString() → C-API read the entire configuration cfg into the string val_ou...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_ReadFile(JNIEnv *env, jobject self, jstring filename)
Java: config.ReadFile(String filename) → C-API This function reads and parses a configuration f...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_Log(JNIEnv *env, jobject self, jobject fmtobj, jint debug, jstring callfunc, jint lvl)
Java: cfg.Log(?MkObjectC fmtobj = null?, ?int debug = 0?, ?String callfunc = null?...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_WriteFile(JNIEnv *env, jobject self, jstring filename)
Java: config.WriteFile(String filename) → C-API This function writes the configuration config t...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_Clear(JNIEnv *env, jobject self)
Java: config.Clear() → C-API Since v1.7 This function clears the configuration config …
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_RootSetting(JNIEnv *env, jobject self)
Java: LcSettingC config.RootSetting() → C-API This function, which is implemented as a macro,...
static void LcConfigSetTabWidth(LC_CFG config, MK_I16 width)
These functions, which are implemented as macros, get and set the tab width for the configuration con...
static void LcConfigSetFloatPrecision(LC_CFG config, MK_I16 digits)
Since v1.6 These functions get and set the number of decimal digits to output after the radix charact...
#define LcConfigSetSettingDeleteFunc(...)
static void LcConfigSetOptions(LC_CFG config, enum LcConfigOptionsEF options)
These functions get and set the options for the configuration config …
static void LcConfigSetOption(LC_CFG config, enum LcConfigOptionsEF option, MK_BOOL flag)
Since v1.7 These functions get and set the given option of the configuration config …
static void LcConfigSetIncludeDir(LC_CFG config, MK_STRN include_dir)
ConfigSetIncludeDir specifies the include directory, include_dir, relative to which the files specifi...
#define LcConfigSetIncludeFunc(...)
static void LcConfigSetDefaultFormat(LC_CFG config, enum LcConfigFormatE format)
These functions, which are implemented as macros, get and set the default external format for setting...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_SetIncludeDir(JNIEnv *env, jobject self, jstring include_dir)
Java: config.SetIncludeDir(String include_dir) → C-API ConfigSetIncludeDir specifies the includ...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_SetDefaultFormat(JNIEnv *env, jobject self, jobject format)
Java: config.SetDefaultFormat(LcConfigFormatE format) → C-API These functions,...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_SetSettingDeleteFunc(JNIEnv *env, jobject self, jobject fSettingDeleteData)
Java: cfg.SetSettingDeleteFunc(?LcSettingDeleteIF fSettingDeleteData = null?) → C-API set the c...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_SetIncludeFunc(JNIEnv *env, jobject self, jobject fConfigIncludeData)
Java: cfg.SetIncludeFunc(?LcConfigIncludeIF fConfigIncludeData = null?) → C-API set the __parse...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_SetOptions(JNIEnv *env, jobject self, jobject options)
Java: config.SetOptions(LcConfigOptionsEF options) → C-API These functions get and set the opti...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_SetFloatPrecision(JNIEnv *env, jobject self, jshort digits)
Java: config.SetFloatPrecision(short digits) → C-API Since v1.6 These functions get and set the...
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_SetOption(JNIEnv *env, jobject self, jobject option, jboolean flag)
Java: config.SetOption(LcConfigOptionsEF option, boolean flag) → C-API Since v1....
JNIEXPORT void JNICALL Java_jvlcconfig_LcConfigC_SetTabWidth(JNIEnv *env, jobject self, jshort width)
Java: config.SetTabWidth(short width) → C-API These functions, which are implemented as macros,...
static LC_CFG LcConfigCreate(MK_TYP type, config_t *nat)
create a LcConfigC instance …
JNIEXPORT jlong JNICALL Java_jvlcconfig_LcConfigC_CTOR(JNIEnv *env, jclass class)
Java: [constructor,static] LcConfigC LcConfigC.Create() → C-API create a LcConfigC instance …
JNIEXPORT jobject JNICALL Java_jvlcconfig_LcConfigC_Create(JNIEnv *env, jclass class)
Java: [constructor,static] LcConfigC LcConfigC.Create() → C-API create a LcConfigC instance …
LcConfigFormatE
set the format of a LcSettingC …
LcConfigOptionsEF
define the configuration-option of a LcConfigC …
MK_STRN LcErrorTypeE_ToString(enum LcErrorTypeE value)
return the LcErrorTypeE as string …
MK_STRN LcConfigFormatE_ToString(enum LcConfigFormatE value)
return the LcConfigFormatE as string …
static MK_ARTIFICIAL LC_CFS LcSettingC_ObjNew(config_setting_t *hdl)
return Programming-Language-Micro-Kernel (PLMK) instance from native hdl …
const struct MkObjectS * MK_OBJN
static MK_I32 MkRuntimeDebugGet(void)
Struct to represent the data from the LcConfigC …
Struct to represent the data from the LcSettingC …