vblcconfig 9.0
Loading...
Searching...
No Matches
vblcconfig

The liblcconfig Project.

SYNOPSIS

The vblcconfig package is a library for processing configuration files

Imports csmsgque.lcconfig

The vblcconfig package is a composition of multiple classes defining the Programming-Language-Micro-Kernel:

object description
csmsgque.lcconfig the namespace with all vblcconfig specific definitions
csmsgque.lcconfig.Attribute the interface to access the package specific attribute
csmsgque.lcconfig.LcClassC.Attribute the interface to access the class specific attribute
Instance.Attribute the interface to access the instance specific attribute

To access all features without csmsgque.lcconfig prefix use:

Imports csmsgque.lcconfig

Using the vblcconfig package …
To access the vblcconfig package the environment variable MONO_PATH have to include the directory.

> man mono

MONO_PATH
      Provides a search path to the runtime where to look for library
      files. This is a tool convenient for debugging applications, but
      should not be used by deployed applications as it breaks the assembly
      loader in subtle ways.
      Directories are separated by the platform path separator (colons on unix). Example:
      /home/username/lib:/usr/local/mono/lib
      Relative paths are resolved based on the launch-time current directory.
      Alternative solutions to MONO_PATH include: installing libraries into
      the Global Assembly Cache (see gacutil(1)) or having the dependent
      libraries side-by-side with the main executable.
      For a complete description of recommended practices for application
      deployment, see
      http://www.mono-project.com/docs/getting-started/application-deployment/

VB automake build hint

Example from vb/Makefile.am Build an Vb.Net executable from the example/vb directory
VB_FILES = Filter1.vb Filter2.vb Filter3.vb Filter4.vb Filter5.vb Filter6.vb \
manfilter.vb mulclient.vb mulserver.vb MyClient.vb MyServer.vb \
server.vb testclient.vb testserver.vb Bug2.vb Bug3.vb \
MyLoopServer.vb MyRouter.vb perfserver.vb MyClient2.vb \
MyTransaction.vb
SUFFIXES = *.exe *.vb *.dll
# get the "dll" from the "cs" (C#) build directory
csmqmsgque := $(theLink_BUILDDIR)/csmsgque/csmqmsgque.dll
csmkkernel := $(theKernel_BUILDDIR)/csmsgque/csmkkernel.dll
cslcconfig := $(theConfig_BUILDDIR)/csmsgque/cslcconfig.dll
# rule to build a "exe" from a "vb" using the 'cs' (C#) library
# !! attention !! - we have a ONE-2-ONE mapping of "vb" to "exe" files
%.exe: $(srcdir)/%.vb $(csmqmsgque) $(csmkkernel)
$(VBCOMP) -nologo $(VB_DEBUG) -reference:$(csmqmsgque) -reference:$(csmkkernel) -out:$@ -target:exe $<
# pattern-rule for all "vb" files found in "srcdir"
ALL = $(patsubst %.vb, $(builddir)/%.exe, $(VB_FILES))
MkKernelRpcServer.dll: MkKernelRpcServer.vb $(csmkkernel) $(csmqmsgque)
$(VBCOMP) -nologo $(VB_DEBUG) -reference:$(csmqmsgque) -reference:$(csmkkernel) -out:$@ -target:library $<
MqMsgqueRpcServer.dll: MqMsgqueRpcServer.vb $(csmkkernel) $(csmqmsgque) MkKernelRpcServer.dll
$(VBCOMP) -nologo $(VB_DEBUG) -reference:$(csmqmsgque) -reference:$(csmkkernel) \
-reference:MkKernelRpcServer.dll -out:$@ -target:library $<
if USE_LIBCONFIG
ALL += ConfigServer.exe
LcConfigRpcServer.dll: LcConfigRpcServer.vb $(csmkkernel) $(csmqmsgque) $(cslcconfig) MkKernelRpcServer.dll
$(VBCOMP) -nologo $(VB_DEBUG) -reference:$(csmqmsgque) -reference:$(csmkkernel) \
-reference:MkKernelRpcServer.dll -reference:$(cslcconfig) -out:$@ -target:library $<
ConfigServer.exe: ConfigServer.vb MkKernelRpcServer.dll MqMsgqueRpcServer.dll LcConfigRpcServer.dll
$(VBCOMP) -nologo $(VB_DEBUG) -reference:$(csmkkernel) -reference:$(csmqmsgque) -reference:$(cslcconfig) \
-reference:MkKernelRpcServer.dll -reference:MqMsgqueRpcServer.dll -reference:LcConfigRpcServer.dll -out:$@ -target:exe $<
endif
##
## ==========================================================================
## Main
##
all-local: $(ALL)
CLEANFILES = *.exe *.mdb *.dll *.pdb
EXTRA_DIST = $(srcdir)/*.vb

VB initialization hint

VB dependency on CSharp

Vb.Net depends on the Microsoft CLS as Runtime.

‍The Common Language Runtime (CLR) is a programming that manages the execution of programs written in any of several supported languages, allowing them to share common object-oriented classes written in any of the languages. It is a part of Microsoft's . NET Framework.

To use the VB Programming-Language-Micro-Kernel it is required to include the C# csmsgque.lcconfig namespace provided by the cs\pkgpostfix.dll library.

INDEX

PACKAGE
Philosophy ,
CLASS
LcConfig PACKAGE , LcConfigC , LcSettingC ,
MISC
Examples

INTRODUCTION

C-API: LC_C_API - The LcConfig API.

vblcconfig is a simple library for processing structured configuration files. The file format is more compact and more readable than XML. And unlike XML, it is type-aware, so it is not necessary to do string parsing in application code.

vblcconfig is very compact – a fraction of the size of the expat XML parser library. This makes it well-suited for memory-constrained systems like handheld devices.

The library includes bindings for languages supported by the Programming-Language-Micro-Kernel. It works on POSIX-compliant UNIX and UNIX-like systems (GNU/Linux, Mac OS X, FreeBSD), Android, and Windows (2000, XP and later).

Introduction

vblcconfig is a library for reading, manipulating, and writing structured configuration files. The library features a fully reentrant parser and includes bindings for both the C and C++ programming languages.

The library runs on modern POSIX-compilant systems, such as Linux, Solaris, and Mac OS X (Darwin), as well as on Microsoft Windows 2000/XP and later (with either Microsoft Visual Studio 2005 or later, or the GNU toolchain via the MinGW environment).

Why Another Configuration File Library?

There are several open-source configuration file libraries available as of this writing. This library was written because each of those libraries falls short in one or more ways. The main features of libconfig that set it apart from the other libraries are:

  • A fully reentrant parser. Independent configurations can be parsed in concurrent threads at the same time.
  • Both C and C++ bindings, as well as hooks to allow for the creation of wrappers in other languages.
  • A simple, structured configuration file format that is more readable and compact than XML and more flexible than the obsolete but prevalent Windows ''INI'' file format.
  • A low-footprint implementation (just 37K for the C library and 76K for the C++ library) that is suitable for memory-constrained systems.
  • Proper documentation.

Multithreading Issues

vblcconfig is fully reentrant; the functions in the library do not make use of global variables and do not maintain state between successive calls. Therefore two independent configurations may be safely manipulated concurrently by two distinct threads.

vblcconfig is not thread-safe. The library is not aware of the presence of threads and knows nothing about the host system's threading model. Therefore, if an instance of a configuration is to be accessed from multiple threads, it must be suitably protected by synchronization mechanisms like read-write locks or mutexes; the standard rules for safe multithreaded access to shared data must be observed.

vblcconfig is not async-safe. Calls should not be made into the library from signal handlers, because some of the C library routines that it uses may not be async-safe.

vblcconfig is not guaranteed to be cancel-safe. Since it is not aware of the host system's threading model, the library does not contain any thread cancellation points. In most cases this will not be an issue for multithreaded programs. However, be aware that some of the routines in the library (namely those that read/write configurations from/to files or streams) perform I/O using C library routines which may potentially block; whether or not these C library routines are cancel-safe depends on the host system.

Internationalization Issues

vblcconfig does not natively support Unicode configuration files, but string values may contain Unicode text encoded in UTF-8; such strings will be treated as ordinary 8-bit ASCII text by the library. It is the responsibility of the calling program to perform the necessary conversions to/from wide (wchar_t) strings using the wide string conversion functions such as mbsrtowcs() and wcsrtombs() or the iconv() function of the libiconv library.

The textual representation of a floating point value varies by locale. However, the libconfig grammar specifies that floating point values are represented using a period ('.') as the radix symbol; this is consistent with the grammar of most programming languages. When a configuration is read in or written out, libconfig temporarily changes the LC_NUMERIC category of the locale of the calling thread to the ''C'' locale to ensure consistent handling of floating point values regardless of the locale(s) in use by the calling program.

Note that the MinGW environment does not (as of this writing) provide functions for changing the locale of the calling thread. Therefore, when using libconfig in that environment, the calling program is responsible for changing the LC_NUMERIC category of the locale to the "C" locale before reading or writing a configuration.

Configuration Files

vblcconfig supports structured, hierarchical configurations. These configurations can be read from and written to files and manipulated in memory.

A configuration consists of a group of settings, which associate names with values. A value can be one of the following:

  • A scalar value: integer, 64-bit integer, floating-point number, boolean, or string
  • An array, which is a sequence of scalar values, all of which must have the same type
  • A group, which is a collection of settings
  • A list, which is a sequence of values of any type, including other lists

Consider the following configuration file for a hypothetical GUI application, which illustrates all of the elements of the configuration file grammar.

# Example application configuration file
version = "1.0";
application:
{
window:
{
title = "My Application";
size = { w = 640; h = 480; };
pos = { x = 350; y = 250; };
};
list = ( ( "abc", 123, true ), 1.234, ( /\* an empty list *\/ ) );
books = ( { title = "Treasure Island";
author = "Robert Louis Stevenson";
price = 29.95;
qty = 5; },
{ title = "Snow Crash";
author = "Neal Stephenson";
price = 9.99;
qty = 8; } );
misc:
{
pi = 3.141592654;
bigint = 9223372036854775807L;
columns = [ "Last Name", "First Name", "MI" ];
bitmask = 0x1FC3; // hex
umask = 0027; // octal. Range limited to that of "int"
};
};


Settings can be uniquely identified within the configuration by a path. The path is a dot-separated sequence of names, beginning at a top-level group and ending at the setting itself. Each name in the path is the name of a setting; if the setting has no name because it is an element in a list or array, an integer index in square brackets can be used as the name.

For example, in our hypothetical configuration file, the path to the x setting is application.window.pos.x; the path to the version setting is simply version; and the path to the title setting of the second book in the books list is application.books.[1].title.

The datatype of a value is determined from the format of the value itself. If the value is enclosed in double quotes, it is treated as a string. If it looks like an integer or floating point number, it is treated as such. If it is one of the values TRUE, true, FALSE, or false (or any other mixed-case version of those tokens, e.g., True or FaLsE), it is treated as a boolean. If it consists of a comma-separated list of values enclosed in square brackets, it is treated as an array. And if it consists of a comma-separated list of values enclosed in parentheses, it is treated as a list. Any value which does not meet any of these criteria is considered invalid and results in a parse error.

All names are case-sensitive. They may consist only of alphanumeric characters, dashes ('-'), underscores ('_'), and asterisks ('*'), and must begin with a letter or asterisk. No other characters are allowed.

In C and C++, integer, 64-bit integer, floating point, and string values are mapped to the native types int, long long, double, and const char *, respectively. The boolean type is mapped to int in C and bool in C++.

The following sections describe the elements of the configuration file grammar in additional detail.

Settings

A setting has the form:

name = value ;

or:

name : value ;

The trailing semicolon is optional. Whitespace is not significant.

The value may be a scalar value, an array, a group, or a list.

Groups

A group has the form:

{ settings ... }

Groups can contain any number of settings, but each setting must have a unique name within the group.

Arrays

An array has the form:

[ value, value ... ]

An array may have zero or more elements, but the elements must all be scalar values of the same type.

The last element in an array may be followed by a comma, which will be ignored.

Lists

A list has the form:

( value, value ... )

A list may have zero or more elements, each of which can be a scalar value, an array, a group, or another list.

The last element in a list may be followed by a comma, which will be ignored.

Integer Values

Integers can be represented in one of two ways: as a series of one or more decimal digits ('0' - '9'), with an optional leading sign character ('+' or '-'); or as a hexadecimal value consisting of the characters '0x' followed by a series of one or more hexadecimal digits ('0' - '9', 'A' - 'F', 'a' - 'f'). Additionally, octal notation integers (that is, those having a leading zero with non-zero value) are also allowed.

64-bit Integer Values

Long long (64-bit) integers are represented identically to integers, except that an 'L' character is appended to indicate a 64-bit value. For example, '0L' indicates a 64-bit integer value 0. As of version 1.5 of the library, the trailing 'L' is optional; if the integer value exceeds the range of a 32-bit integer, it will automatically be interpreted as a 64-bit integer.

The integer and 64-bit integer setting types are interchangeable to the extent that a conversion between the corresponding native types would not result in an overflow or underflow. For example, a long long value can be written to a setting that has an integer type, if that value is within the range of an int. This rule applies to every API function or method that reads a value from or writes a value to a setting: if the type conversion would not result in an overflow or underflow, then the call will succeed, and otherwise it will fail. This behavior was not well-defined prior to version 1.7 of the library.

Floating Point Values

Floating point values consist of a series of one or more digits, one decimal point, an optional leading sign character ('+' or '-'), and an optional exponent. An exponent consists of the letter 'E' or 'e', an optional sign character, and a series of one or more digits.

Boolean Values

Boolean values may have one of the following values: 'true', 'false', or any mixed-case variation thereof.

String Values

String values consist of arbitrary text delimited by double quotes. Literal double quotes can be escaped by preceding them with a backslash: '\"'. The escape sequences '\\', '\f', '\n', '\r', and '\t' are also recognized, and have the usual meaning.

In addition, the '\x' escape sequence is supported; this sequence must be followed by exactly two hexadecimal digits, which represent an 8-bit ASCII value. For example, '\xFF' represents the character with ASCII code 0xFF.

No other escape sequences are currently supported.

Adjacent strings are automatically concatenated, as in C/C++ source code. This is useful for formatting very long strings as sequences of shorter strings. For example, the following constructs are equivalent:

  • "The quick brown fox jumped over the lazy dog."
  • "The quick brown fox"
    " jumped over the lazy dog."
  • "The quick" /* comment *\/ " brown fox " // another comment
    "jumped over the lazy dog."

Comments

Three types of comments are allowed within a configuration:

  • Script-style comments. All text beginning with a '#' character to the end of the line is ignored.
  • C-style comments. All text, including line breaks, between a starting '/*' sequence and an ending '*\/' sequence is ignored.
  • C++-style comments. All text beginning with a '//' sequence to the end of the line is ignored.

As expected, comment delimiters appearing within quoted strings are treated as literal text.

Comments are ignored when the configuration is read in, so they are not treated as part of the configuration. Therefore if the configuration is written back out to a stream, any comments that were present in the original configuration will be lost.

Include Directives

A configuration file may ''include'' the contents of other files using an include directive. This directive has the effect of inlining the contents of the named file(s) at the point of inclusion.

An include directive must appear on its own line in the input. It has the form:

@include "path"

The interpretation of path depends on the currently registered include function. The default include function prepends the include directory, if any, to path, and then interprets the result as a single, literal file path. The application may supply its own include function which does variable substitution, wildcard expansion, or other transformations, returning a list of zero or more paths to files whose contents should be inlined at the point of inclusion.

Any backslashes or double quotes in the path must be escaped as '\\' and '\"', respectively.

For example, consider the following two configuration files:

# file: quote.cfg
quote = "Criticism may not be agreeable, but it is necessary."
" It fulfils the same function as pain in the human"
" body. It calls attention to an unhealthy state of"
" things.\\n"
"\\t--Winston Churchill";
# file: test.cfg
info: {
name = "Winston Churchill";
@include "quote.cfg"
country = "UK";
};

The resulting configuration will be equivalent to one in which the contents of the file 'quote.cfg' appeared at the point where the include directive is placed.

Include files may be nested to a maximum of 10 levels; exceeding this limit results in a parse error.

When the path argument to an @include directive is a relative path, then it will be interpreted as being relative to the include directory that has been been set by means of ConfigSetIncludeDir. If no include directory has been set, then it will be taken as being relative to the program's current working directory.

Like comments, include directives are not part of the configuration file syntax. They are processed before the configuration itself is parsed. Therefore, they are not preserved when the configuration is written back out to a stream. There is presently no support for programmatically inserting include directives into a configuration.

The C API

This chapter describes the C library API. The type LcConfigC represents a configuration, and the type LcSettingC represents a configuration setting.

The boolean values CONFIG_TRUE and CONFIG_FALSE are macros defined as (1) and (0), respectively.

License

The libconfig library uses the GNU license:

and uses the official website for reference:

The following authors are involved :

author role
Mark Lindner Lead developer & maintainer.
Daniel Marjamäki Enhancements & bugfixes.
Andrew Tytula Windows port.
Glenn Herteg Enhancements, bugfixes, documentation corrections.
Matt Renaud Enhancements & bugfixes.
JoseLuis Tallon Enhancements & bugfixes

LcConfig PACKAGE

LcConfig ENUM

enum LcConfigFormatEset the format of a LcSettingC
ConfigFormatE_FromIntreturn the LcConfigFormatE from integer …
ConfigFormatE_ToIntreturn the LcConfigFormatE as integer …
ConfigFormatE_ToStringreturn the LcConfigFormatE as string …
enum LcConfigOptionsEFconfiguration options for config-file-layout
ConfigOptionsEF_FromIntreturn the LcConfigOptionsEF from integer …
ConfigOptionsEF_ToIntreturn the LcConfigOptionsEF as integer …
ConfigOptionsEF_ToStringBEGIN-LcConfigOptionsEF - created by 'c_MqS.tcl -i NHI1_HOME/theConfig/liblcconfig/.liblcconfig.meta' - DO NOT change.
enum LcConfigTypeE
ConfigTypeE_FromIntreturn the LcConfigTypeE from integer …
ConfigTypeE_ToIntreturn the LcConfigTypeE as integer …
ConfigTypeE_ToStringreturn the LcConfigTypeE as string …
enum LcErrorESignals an error and is used as the return value of a function …
ErrorE_FromIntreturn the LcErrorE from integer …
ErrorE_ToIntreturn the LcErrorE as integer …
ErrorE_ToStringreturn the LcErrorE as string …
enum LcErrorTypeE
ErrorTypeE_FromIntreturn the LcErrorTypeE from integer …
ErrorTypeE_ToIntreturn the LcErrorTypeE as integer …
ErrorTypeE_ToString

return the LcErrorTypeE as string …

LcConfig SETUP

Cleanupcleanup vblcconfig internal memory …
Setup

setup vblcconfig internal memory …

LcConfig DETAIL

C-API: LcConfig_C_API - The package is the toplevel structure of the Programming-Language-Micro-Kernel

The vblcconfig package is loaded with:

Imports csmsgque.lcconfig

and is a composition of one or more package-item and exact one package-main.

The vblcconfig package add the following classes into MkObjectC_C_API :

Object C-Short Description
LcConfigC LC_CFG The LcConfigC object known as cfg or config is the main data structure …
LcSettingC LC_CFS The LcSettingC object known as cfs or setting is the main data structure.

The vblcconfig package add the following types into MkObjectC_C_API :

    ABSTRACT: MkTypeSTT (TypeTypeType = type of a TypeType)
    |
    |- ABSTRACT: MkDefTypeSTT (TypeType = type of a Type)
       |
       |- LcConfigST, LcSettingT
Attention
Vb.Net is a CLR extension and use the same code as C#

LcConfig ENUM

C-API: LcConfig_Enum_C_API - C-API: Internal - Enum definition - vblcconfig enum definition …

A enum in the Programming-Language-Micro-Kernel is a enum-data-type and 3 enum-access-attributes

  1. ENUM_ToString → return the string-value from the enum-value
  2. ENUM_ToInt → return the integer-value from the enum-value
  3. ENUM_FromInt → create an enum-value from an integer-value.

The enum-data-type and the 3 enum-access-attributes are defined in all target-languages (C,C++,C#,VB.NET,Java,Python,Ruby,Perl,PHP,Tcl or GO).

enum LcConfigFormatE

TOP

set the format of a LcSettingC … → API: csmsgque.lcconfig.LcConfigFormatE

[static] ConfigFormatE_FromInt(value As Integer) As LcConfigFormatE

TOP

return the LcConfigFormatE from integer … → API: csmsgque.lcconfig.LcConfig.ConfigFormatE_FromInt

reference for original

[static] ConfigFormatE_ToInt(value As LcConfigFormatE) As Integer

TOP

return the LcConfigFormatE as integer … → API: csmsgque.lcconfig.LcConfig.ConfigFormatE_ToInt

reference for original

[static] ConfigFormatE_ToString(value As LcConfigFormatE) As String

TOP

return the LcConfigFormatE as string … → API: csmsgque.lcconfig.LcConfig.ConfigFormatE_ToString

reference for original

enum LcConfigOptionsEF

TOP

configuration options for config-file-layout → API: csmsgque.lcconfig.LcConfigOptionsEF

[static] ConfigOptionsEF_FromInt(value As Integer) As LcConfigOptionsEF

TOP

return the LcConfigOptionsEF from integer … → API: csmsgque.lcconfig.LcConfig.ConfigOptionsEF_FromInt

reference for original

[static] ConfigOptionsEF_ToInt(value As LcConfigOptionsEF) As Integer

TOP

return the LcConfigOptionsEF as integer … → API: csmsgque.lcconfig.LcConfig.ConfigOptionsEF_ToInt

reference for original

[static] ConfigOptionsEF_ToString(value As LcConfigOptionsEF) As String

TOP

BEGIN-LcConfigOptionsEF - created by 'c_MqS.tcl -i NHI1_HOME/theConfig/liblcconfig/.liblcconfig.meta' - DO NOT change. → API: csmsgque.lcconfig.LcConfig.ConfigOptionsEF_ToString

return the LcConfigOptionsEF as string …

reference for original

enum LcConfigTypeE

TOP

→ API: csmsgque.lcconfig.LcConfigTypeE

[static] ConfigTypeE_FromInt(value As Integer) As LcConfigTypeE

TOP

return the LcConfigTypeE from integer … → API: csmsgque.lcconfig.LcConfig.ConfigTypeE_FromInt

reference for original

[static] ConfigTypeE_ToInt(value As LcConfigTypeE) As Integer

TOP

return the LcConfigTypeE as integer … → API: csmsgque.lcconfig.LcConfig.ConfigTypeE_ToInt

reference for original

[static] ConfigTypeE_ToString(value As LcConfigTypeE) As String

TOP

return the LcConfigTypeE as string … → API: csmsgque.lcconfig.LcConfig.ConfigTypeE_ToString

reference for original

enum LcErrorE

TOP

Signals an error and is used as the return value of a function … → API: csmsgque.lcconfig.LcErrorE

[static] ErrorE_FromInt(value As Integer) As LcErrorE

TOP

return the LcErrorE from integer … → API: csmsgque.lcconfig.LcConfig.ErrorE_FromInt

reference for original

[static] ErrorE_ToInt(value As LcErrorE) As Integer

TOP

return the LcErrorE as integer … → API: csmsgque.lcconfig.LcConfig.ErrorE_ToInt

reference for original

[static] ErrorE_ToString(value As LcErrorE) As String

TOP

return the LcErrorE as string … → API: csmsgque.lcconfig.LcConfig.ErrorE_ToString

reference for original

enum LcErrorTypeE

TOP

→ API: csmsgque.lcconfig.LcErrorTypeE

[static] ErrorTypeE_FromInt(value As Integer) As LcErrorTypeE

TOP

return the LcErrorTypeE from integer … → API: csmsgque.lcconfig.LcConfig.ErrorTypeE_FromInt

reference for original

[static] ErrorTypeE_ToInt(value As LcErrorTypeE) As Integer

TOP

return the LcErrorTypeE as integer … → API: csmsgque.lcconfig.LcConfig.ErrorTypeE_ToInt

reference for original

[static] ErrorTypeE_ToString(value As LcErrorTypeE) As String

TOP

return the LcErrorTypeE as string … → API: csmsgque.lcconfig.LcConfig.ErrorTypeE_ToString

reference for original

LcConfig SETUP

C-API: LcConfig_Setup_C_API - Setup und Cleanup the vblcconfig

For details about Setup and Cleanup usage refer to MkKernel_Setup_C_API

[static] Cleanup()

TOP

cleanup vblcconfig internal memory … → API: csmsgque.lcconfig.LcConfig.Cleanup

MkCleanup can only be called once and will be ignored if not called in the same thread as LcSetup. after a call to LcSetup the call to MkCleanup is possible again.

Attention
during cleanup objects will be deleted too -> the language interpreter have to be active

reference for original

[static] Setup()

TOP

setup vblcconfig internal memory … → API: csmsgque.lcconfig.LcConfig.Setup

LcSetup can only be called once, additional call's will be ignored until a LcCleanup is called.

reference for original


LcConfigC

LcConfigC ERROR

ErrorType

This function, which is implemented as a macro, returns the type of error that occurred during the last call to one of the read or write functions …

LcConfigC GET

GetDefaultFormatThese functions, which are implemented as macros, get and set the default external format for settings in the configuration config
GetFloatPrecisionSince v1.6 These functions get and set the number of decimal digits to output after the radix character when writing the configuration to a file or stream …
GetIncludeDirConfigSetIncludeDir specifies the include directory, include_dir, relative to which the files specified in '@include' directives will be located for the configuration config
GetOptionSince v1.7 These functions get and set the given option of the configuration config
GetOptionsThese functions get and set the options for the configuration config
GetTabWidth

These functions, which are implemented as macros, get and set the tab width for the configuration config

LcConfigC INTROSPECTION

Instancesget head-instance from linked-list of LcConfigS type …
Nextget next instance from linked-list of LcConfigS type
Prev

get previous instance from linked-list of LcConfigS type

LcConfigC LOOKUP

LookupThis function locates the setting in the configuration config specified by the path path
LookupBoolThese functions look up the value of the setting in the configuration config specified by the path path
LookupFloatThese functions look up the value of the setting in the configuration config specified by the path path
LookupIntThese functions look up the value of the setting in the configuration config specified by the path path
LookupInt64These functions look up the value of the setting in the configuration config specified by the path path
LookupString

These functions look up the value of the setting in the configuration config specified by the path path

LcConfigC MISC

ClearSince v1.7 This function clears the configuration config
Loglog the config
ReadFileThis function reads and parses a configuration from the file named filename into the configuration object config
ReadStringThis function reads and parses a configuration from the string str into the configuration object config
RootSettingThis function, which is implemented as a macro, returns the root setting for the configuration config
WriteFileThis function writes the configuration config to the file named filename
WriteString

read the entire configuration cfg into the string val_out

LcConfigC SET

SetDefaultFormatThese functions, which are implemented as macros, get and set the default external format for settings in the configuration config
SetFloatPrecisionSince v1.6 These functions get and set the number of decimal digits to output after the radix character when writing the configuration to a file or stream …
SetIncludeDirConfigSetIncludeDir specifies the include directory, include_dir, relative to which the files specified in '@include' directives will be located for the configuration config
SetIncludeFunc
SetOptionSince v1.7 These functions get and set the given option of the configuration config
SetOptionsThese functions get and set the options for the configuration config
SetSettingDeleteFunccallback called on delete a setting, used to cleanup user data…
SetTabWidth

These functions, which are implemented as macros, get and set the tab width for the configuration config

LcConfigC TOR

Createcreate a LcConfigC instance …
FromHandlereturn a LcConfigC from exporthdl
Delete

delete a LcConfigC instance …

LcConfigC DETAIL

C-API: LcConfigC_C_API - The LcConfigC object known as cfg or config is the main data structure …

LcConfigC ERROR

C-API: LcConfigC_Error_C_API - various functions to set the configuration of the LcConfigC

config.ErrorType() As LcErrorTypeE

TOP

This function, which is implemented as a macro, returns the type of error that occurred during the last call to one of the read or write functions … → API: csmsgque.lcconfig.LcConfigC.ErrorType

The LcErrorTypeE type is an enumeration with the following values: CONFIG_ERR_NONE, CONFIG_ERR_FILE_IO, CONFIG_ERR_PARSE. These represent success, a file I/O error, and a parsing error, respectively.

LcConfigC GET

C-API: LcConfigC_Get_C_API - various functions to get the configuration of the LcConfigC

config.GetDefaultFormat() As LcConfigFormatE

TOP

These functions, which are implemented as macros, get and set the default external format for settings in the configuration config … → API: csmsgque.lcconfig.LcConfigC.GetDefaultFormat

If a non-default format has not been set for a setting with config_setting_set_format, this configuration-wide default format will be used instead when that setting is written to a file or stream.

See also
ConfigSetDefaultFormat

config.GetFloatPrecision() As Short

TOP

Since v1.6 These functions get and set the number of decimal digits to output after the radix character when writing the configuration to a file or stream … → API: csmsgque.lcconfig.LcConfigC.GetFloatPrecision

Valid values for digits range from 0 (no decimals) to about 15 (implementation defined). This parameter has no effect on parsing.

The default float precision is 6.

See also
ConfigSetFloatPrecision

config.GetIncludeDir() As String

TOP

ConfigSetIncludeDir specifies the include directory, include_dir, relative to which the files specified in '@include' directives will be located for the configuration config … → API: csmsgque.lcconfig.LcConfigC.GetIncludeDir

By default, there is no include directory, and all include files are expected to be relative to the current working directory. If include_dir is NULL, the default behavior is reinstated.

For example, if the include directory is set to /usr/local/etc, the include directive '@include "configs/extra.cfg"' would include the file /usr/local/etc/configs/extra.cfg.

ConfigGetIncludeDir returns the current include directory for the configuration config, or NULL if none is set.

See also
ConfigSetIncludeDir

config.GetOption(option As LcConfigOptionsEF) As Boolean

TOP

Since v1.7 These functions get and set the given option of the configuration config … → API: csmsgque.lcconfig.LcConfigC.GetOption

The option is enabled if flag is CONFIG_TRUE and disabled if it is CONFIG_FALSE.

See ConfigSetOptions above for the list of available options.

See also
ConfigSetOption

config.GetOptions() As LcConfigOptionsEF

TOP

These functions get and set the options for the configuration config … → API: csmsgque.lcconfig.LcConfigC.GetOptions

The options affect how configurations are read and written. The following options are defined:

CONFIG_OPTION_AUTOCONVERT

Turning this option on enables number auto-conversion for the configuration. When this feature is enabled, an attempt to retrieve a floating point setting's value into an integer (or vice versa), or store an integer to a floating point setting's value (or vice versa) will cause the library to silently perform the necessary conversion (possibly leading to loss of data), rather than reporting failure. By default this option is turned off.

CONFIG_OPTION_SEMICOLON_SEPARATORS

This option controls whether a semicolon (';') is output after each setting when the configuration is written to a file or stream. (The semicolon separators are optional in the configuration syntax.) By default this option is turned on.

CONFIG_OPTION_COLON_ASSIGNMENT_FOR_GROUPS

This option controls whether a colon (':') is output between each group setting's name and its value when the configuration is written to a file or stream. If the option is turned off, an equals sign ('=') is output instead. (These tokens are interchangeable in the configuration syntax.) By default this option is turned on.

CONFIG_OPTION_COLON_ASSIGNMENT_FOR_NON_GROUPS

This option controls whether a colon (':') is output between each non-group setting's name and its value when the configuration is written to a file or stream. If the option is turned off, an equals sign ('=') is output instead. (These tokens are interchangeable in the configuration syntax.) By default this option is turned off.

CONFIG_OPTION_OPEN_BRACE_ON_SEPARATE_LINE

This option controls whether an open brace ('{') will be written on its own line when the configuration is written to a file or stream. If the option is turned off, the brace will be written at the end of the previous line. By default this option is turned on.

CONFIG_OPTION_ALLOW_SCIENTIFIC_NOTATION

(Since v1.7) This option controls whether scientific notation may be used as appropriate when writing floating point values (corresponding to printf 'g' format) or should never be used (corresponding to printf 'f' format). By default this option is turned off.

CONFIG_OPTION_FSYNC

(Since v1.7.1) This option controls whether the ConfigWriteFile function performs an fsync operation after writing the configuration and before closing the file. By default this option is turned off.

CONFIG_OPTION_ALLOW_OVERRIDES

(Since v1.7.3) This option controls whether duplicate settings override previous settings with the same name. If this option is turned off, duplicate settings are rejected. By default this option is turned off.

See also
ConfigSetOptions

config.GetTabWidth() As Short

TOP

These functions, which are implemented as macros, get and set the tab width for the configuration config … → API: csmsgque.lcconfig.LcConfigC.GetTabWidth

The tab width affects the formatting of the configuration when it is written to a file or stream: each level of nesting is indented by width spaces, or by a single tab character if width is 0. The tab width has no effect on parsing.

Valid tab widths range from 0 to 15. The default tab width is 2.

See also
ConfigSetTabWidth

LcConfigC INTROSPECTION

C-API: LcConfigC_Introspection_C_API - Get information about all instances created by class

[static] LcConfigC.Instances() As LcConfigC

TOP

get head-instance from linked-list of LcConfigS type … → API: csmsgque.lcconfig.LcConfigC.Instances

The head-instance is the last instance created.

reference for original

cfg.Next() As LcConfigC

TOP

get next instance from linked-list of LcConfigS type → API: csmsgque.lcconfig.LcConfigC.Next

reference for original

cfg.Prev() As LcConfigC

TOP

get previous instance from linked-list of LcConfigS type → API: csmsgque.lcconfig.LcConfigC.Prev

reference for original

LcConfigC LOOKUP

C-API: LcConfigC_Lookup_C_API - locates the setting in the configuration and return the data or an LcSettingC

This function locates the setting in the configuration config specified by the path path. It returns a pointer to the LcSettingC structure on success, or NULL if the setting was not found.

config.Lookup(path As String) As LcSettingC

TOP

This function locates the setting in the configuration config specified by the path path … → API: csmsgque.lcconfig.LcConfigC.Lookup

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

config.LookupBool(path As String) As Boolean

TOP

These functions look up the value of the setting in the configuration config specified by the path path … → API: csmsgque.lcconfig.LcConfigC.LookupBool

They store the value of the setting 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 ConfigLookupString 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
ConfigLookupFloat, ConfigLookupInt, ConfigLookupInt64, ConfigLookupString

config.LookupFloat(path As String) As Double

TOP

These functions look up the value of the setting in the configuration config specified by the path path … → API: csmsgque.lcconfig.LcConfigC.LookupFloat

They store the value of the setting 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 ConfigLookupString 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
ConfigLookupBool, ConfigLookupInt, ConfigLookupInt64, ConfigLookupString

config.LookupInt(path As String) As Integer

TOP

These functions look up the value of the setting in the configuration config specified by the path path … → API: csmsgque.lcconfig.LcConfigC.LookupInt

They store the value of the setting 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 ConfigLookupString 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
ConfigLookupBool, ConfigLookupFloat, ConfigLookupInt64, ConfigLookupString

config.LookupInt64(path As String) As Long

TOP

These functions look up the value of the setting in the configuration config specified by the path path … → API: csmsgque.lcconfig.LcConfigC.LookupInt64

They store the value of the setting 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 ConfigLookupString 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
ConfigLookupBool, ConfigLookupFloat, ConfigLookupInt, ConfigLookupString

config.LookupString(path As String) As String

TOP

These functions look up the value of the setting in the configuration config specified by the path path … → API: csmsgque.lcconfig.LcConfigC.LookupString

They store the value of the setting 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 ConfigLookupString 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
ConfigLookupBool, ConfigLookupFloat, ConfigLookupInt, ConfigLookupInt64

LcConfigC MISC

C-API: LcConfigC_Misc_C_API - various functions to perform misc operations on a LcConfigC

config.Clear()

TOP

Since v1.7 This function clears the configuration config … → API: csmsgque.lcconfig.LcConfigC.Clear

All child settings of the root setting are recursively destroyed. All other attributes of the configuration are left unchanged.

cfg.Log(Optional fmtobj As MkObjectC = null, Optional debug As Integer = 0, Optional callfunc As String = FUNC, Optional lvl As Integer = 0)

TOP

log the config … → API: csmsgque.lcconfig.LcConfigC.Log

Parameters
[in]mkrtthe MkRuntimeS instance to work on - the runtime argument, used by MK_RT_CALL (C-only)
[in]cfgProgramming-Language-Micro-Kernel instance from config_t
[in]fmtobjmanaged object used to format the log-message (default=NULL = use default format)
[in]debugthe debug level from MkRuntimeS::debug, use 0 <= debug <= 9 (default=0)
[in]callfunca user-defined postfix to identify the calling function or the environment (default=name-of-function)
[in]lvla user-defined prefix starting with "" for lvl=0 and increase with " " for lvl+1 (default=0)

config.ReadFile(filename As String)

TOP

This function reads and parses a configuration from the file named filename into the configuration object config … → API: csmsgque.lcconfig.LcConfigC.ReadFile

It returns CONFIG_TRUE on success, or CONFIG_FALSE on failure; the config_error_text and config_error_line functions, described below, can be used to obtain information about the error.

config.ReadString(str As String)

TOP

This function reads and parses a configuration from the string str into the configuration object config … → API: csmsgque.lcconfig.LcConfigC.ReadString

It returns CONFIG_TRUE on success, or CONFIG_FALSE on failure; the config_error_text and config_error_line functions, described below, can be used to obtain information about the error.

config.RootSetting() As LcSettingC

TOP

This function, which is implemented as a macro, returns the root setting for the configuration config … → API: csmsgque.lcconfig.LcConfigC.RootSetting

The root setting is a group.

config.WriteFile(filename As String)

TOP

This function writes the configuration config to the file named filename … → API: csmsgque.lcconfig.LcConfigC.WriteFile

It returns CONFIG_TRUE on success, or CONFIG_FALSE on failure.

cfg.WriteString() As String

TOP

read the entire configuration cfg into the string val_out … → API: csmsgque.lcconfig.LcConfigC.WriteString

Parameters
[in]mkrtthe MkRuntimeS instance to work on - the runtime argument, used by MK_RT_CALL (C-only)
[in]cfgProgramming-Language-Micro-Kernel instance from config_t
[out]val_outthe entire configuration as string - value owed by cfg.WriteString() As String .
Returns
set the MkErrorC to the status MK_OK, MK_CONTINUE or MK_ERROR

LcConfigC SET

C-API: LcConfigC_Set_C_API - various functions to set the configuration of the LcConfigC

config.SetDefaultFormat(format As LcConfigFormatE)

TOP

These functions, which are implemented as macros, get and set the default external format for settings in the configuration config … → API: csmsgque.lcconfig.LcConfigC.SetDefaultFormat

If a non-default format has not been set for a setting with config_setting_set_format, this configuration-wide default format will be used instead when that setting is written to a file or stream.

See also
ConfigGetDefaultFormat

config.SetFloatPrecision(digits As Short)

TOP

Since v1.6 These functions get and set the number of decimal digits to output after the radix character when writing the configuration to a file or stream … → API: csmsgque.lcconfig.LcConfigC.SetFloatPrecision

Valid values for digits range from 0 (no decimals) to about 15 (implementation defined). This parameter has no effect on parsing.

The default float precision is 6.

See also
ConfigGetFloatPrecision

config.SetIncludeDir(include_dir As String)

TOP

ConfigSetIncludeDir specifies the include directory, include_dir, relative to which the files specified in '@include' directives will be located for the configuration config … → API: csmsgque.lcconfig.LcConfigC.SetIncludeDir

By default, there is no include directory, and all include files are expected to be relative to the current working directory. If include_dir is NULL, the default behavior is reinstated.

For example, if the include directory is set to /usr/local/etc, the include directive '@include "configs/extra.cfg"' would include the file /usr/local/etc/configs/extra.cfg.

ConfigGetIncludeDir returns the current include directory for the configuration config, or NULL if none is set.

See also
ConfigGetIncludeDir

cfg.SetIncludeFunc(fConfigIncludeData As LcConfigIncludeF)

TOP

→ API: csmsgque.lcconfig.LcConfigC.SetIncludeFunc

config.SetOption(option As LcConfigOptionsEF, flag As Boolean)

TOP

Since v1.7 These functions get and set the given option of the configuration config … → API: csmsgque.lcconfig.LcConfigC.SetOption

The option is enabled if flag is CONFIG_TRUE and disabled if it is CONFIG_FALSE.

See ConfigSetOptions above for the list of available options.

See also
ConfigGetOption

config.SetOptions(options As LcConfigOptionsEF)

TOP

These functions get and set the options for the configuration config … → API: csmsgque.lcconfig.LcConfigC.SetOptions

The options affect how configurations are read and written. The following options are defined:

CONFIG_OPTION_AUTOCONVERT

Turning this option on enables number auto-conversion for the configuration. When this feature is enabled, an attempt to retrieve a floating point setting's value into an integer (or vice versa), or store an integer to a floating point setting's value (or vice versa) will cause the library to silently perform the necessary conversion (possibly leading to loss of data), rather than reporting failure. By default this option is turned off.

CONFIG_OPTION_SEMICOLON_SEPARATORS

This option controls whether a semicolon (';') is output after each setting when the configuration is written to a file or stream. (The semicolon separators are optional in the configuration syntax.) By default this option is turned on.

CONFIG_OPTION_COLON_ASSIGNMENT_FOR_GROUPS

This option controls whether a colon (':') is output between each group setting's name and its value when the configuration is written to a file or stream. If the option is turned off, an equals sign ('=') is output instead. (These tokens are interchangeable in the configuration syntax.) By default this option is turned on.

CONFIG_OPTION_COLON_ASSIGNMENT_FOR_NON_GROUPS

This option controls whether a colon (':') is output between each non-group setting's name and its value when the configuration is written to a file or stream. If the option is turned off, an equals sign ('=') is output instead. (These tokens are interchangeable in the configuration syntax.) By default this option is turned off.

CONFIG_OPTION_OPEN_BRACE_ON_SEPARATE_LINE

This option controls whether an open brace ('{') will be written on its own line when the configuration is written to a file or stream. If the option is turned off, the brace will be written at the end of the previous line. By default this option is turned on.

CONFIG_OPTION_ALLOW_SCIENTIFIC_NOTATION

(Since v1.7) This option controls whether scientific notation may be used as appropriate when writing floating point values (corresponding to printf 'g' format) or should never be used (corresponding to printf 'f' format). By default this option is turned off.

CONFIG_OPTION_FSYNC

(Since v1.7.1) This option controls whether the ConfigWriteFile function performs an fsync operation after writing the configuration and before closing the file. By default this option is turned off.

CONFIG_OPTION_ALLOW_OVERRIDES

(Since v1.7.3) This option controls whether duplicate settings override previous settings with the same name. If this option is turned off, duplicate settings are rejected. By default this option is turned off.

See also
ConfigGetOptions

cfg.SetSettingDeleteFunc(fSettingDeleteData As LcSettingDeleteF)

TOP

callback called on delete a setting, used to cleanup user data… → API: csmsgque.lcconfig.LcConfigC.SetSettingDeleteFunc

config.SetTabWidth(width As Short)

TOP

These functions, which are implemented as macros, get and set the tab width for the configuration config … → API: csmsgque.lcconfig.LcConfigC.SetTabWidth

The tab width affects the formatting of the configuration when it is written to a file or stream: each level of nesting is indented by width spaces, or by a single tab character if width is 0. The tab width has no effect on parsing.

Valid tab widths range from 0 to 15. The default tab width is 2.

See also
ConfigGetTabWidth

LcConfigC TOR

C-API: LcConfigC_TOR_C_API - various functions to create, initialize and destroy a LcConfigC

[constructor] LcConfigC.Create()

TOP

create a LcConfigC instance … → API: csmsgque.lcconfig.LcConfigC.Create

Parameters
[in]typethe MkTypeS instance to work on - class-type with base LcConfigS - (default = NULL = LcConfigS)
[in]natexternal nat pointer - (default: NULL = internal)
Returns
instance of LcConfigC or NULL if setup failed

[static] LcConfigC.FromHandle(exporthdl As long) As LcConfigC

TOP

return a LcConfigC from exporthdl… → API: csmsgque.lcconfig.LcConfigC.FromHandle

reference for original

[destructor] cfg.Delete()

TOP

delete a LcConfigC instance … → API: LcConfigDelete_RT


LcSettingC

LcSettingC GET

GetBoolThese functions return the value of the given setting
GetBoolElemThese functions return the value at the specified index index in the setting setting
GetConfigaddon - return the LcConfigC from the LcSettingC
GetElemThis function fetches the element at the given index index in the setting setting, which must be an array, list, or group …
GetFloatThese functions return the value of the given setting
GetFloatElemThese functions return the value at the specified index index in the setting setting
GetFormatThese functions get and set the external format for the setting setting
GetIntThese functions return the value of the given setting
GetInt64These functions return the value of the given setting
GetInt64ElemThese functions return the value at the specified index index in the setting setting
GetIntElemThese functions return the value at the specified index index in the setting setting
GetMemberThis function fetches the child setting named name from the group setting
GetStringThese functions return the value of the given setting
GetStringElem

These functions return the value at the specified index index in the setting setting

LcSettingC INTROSPECTION

Instancesget head-instance from linked-list of LcSettingS type …
Nextget next instance from linked-list of LcSettingS type
Prev

get previous instance from linked-list of LcSettingS type

LcSettingC IS

IsAggregateThese convenience functions, some of which are implemented as macros, test if the setting setting is of an aggregate type (a group, array, or list), of a scalar type (integer, 64-bit integer, floating point, boolean, or string), and of a number (integer, 64-bit integer, or floating point), respectively …
IsArrayThese convenience functions, which are implemented as macros, test if the setting setting is of a given type …
IsGroupThese convenience functions, which are implemented as macros, test if the setting setting is of a given type …
IsListThese convenience functions, which are implemented as macros, test if the setting setting is of a given type …
IsNumberThese convenience functions, some of which are implemented as macros, test if the setting setting is of an aggregate type (a group, array, or list), of a scalar type (integer, 64-bit integer, floating point, boolean, or string), and of a number (integer, 64-bit integer, or floating point), respectively …
IsRootThis function returns CONFIG_TRUE if the given setting is the root setting, and CONFIG_FALSE otherwise …
IsScalar

These convenience functions, some of which are implemented as macros, test if the setting setting is of an aggregate type (a group, array, or list), of a scalar type (integer, 64-bit integer, floating point, boolean, or string), and of a number (integer, 64-bit integer, or floating point), respectively …

LcSettingC LOOKUP

LookupThis function locates a setting by a path path relative to the setting setting
LookupAlladdon - read an entire configuration below setting into MkBufferListC
LookupBoolThese functions look up the value of the child setting named name of the setting setting
LookupFloatThese functions look up the value of the child setting named name of the setting setting
LookupIntThese functions look up the value of the child setting named name of the setting setting
LookupInt64These functions look up the value of the child setting named name of the setting setting
LookupString

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

LcSettingC MISC

AddIfNotExistsaddon - add name with type only if not exists in the setting
Existsaddon - return true if name exists in the setting otherwise false
IndexThis function returns the index of the given setting within its parent setting …
LengthThis function returns the number of settings in a group, or the number of elements in a list or array …
Loglog the setting
NameThis function returns the name of the given setting, or NULL if the setting has no name …
ParentThis function returns the parent setting of the given setting, or NULL if setting is the root setting …
RemoveThis function removes and destroys the setting named name from the parent setting parent, which must be a group …
RemoveElemThis function removes the child setting at the given index index from the setting parent, which must be a group, list, or array …
SourceFileThis function returns the name of the file from which the setting setting was read, or NULL if the setting was not read from a file …
SourceLineThis function returns the line number of the configuration file or stream at which the setting setting was read, or 0 if no line number is available …
Type

This function returns the type of the given setting

LcSettingC SET

SetBoolThese functions set the value of the given setting to value
SetBoolElemThese functions set the value at the specified index index in the setting setting to value
SetFloatThese functions set the value of the given setting to value
SetFloatElemThese functions set the value at the specified index index in the setting setting to value
SetFormatThese functions get and set the external format for the setting setting
SetIntThese functions set the value of the given setting to value
SetInt64These functions set the value of the given setting to value
SetInt64ElemThese functions set the value at the specified index index in the setting setting to value
SetIntElemThese functions set the value at the specified index index in the setting setting to value
SetStringThese functions set the value of the given setting to value
SetStringElem

These functions set the value at the specified index index in the setting setting to value

LcSettingC TOR

FromHandlereturn a LcSettingC from exporthdl
Add

This function adds a new child setting or element to the setting parent, which must be a group, array, or list …

LcSettingC DETAIL

C-API: LcSettingC_C_API - The LcSettingC object known as cfs or setting is the main data structure.

LcSettingC GET

C-API: LcSettingC_Get_C_API - various functions to get data from a LcSettingC

setting.GetBool() As Boolean

TOP

These functions return the value of the given setting … → API: csmsgque.lcconfig.LcSettingC.GetBool

If the type of the setting does not match the type requested, a 0 or NULL value is returned. Storage for the string returned by config_setting_get_string 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
SettingGetFloat, SettingGetInt, SettingGetInt64, SettingGetString

setting.GetBoolElem(idx As Integer) As Boolean

TOP

These functions return the value at the specified index index in the setting setting … → API: csmsgque.lcconfig.LcSettingC.GetBoolElem

If the setting is not an array or list, or if the type of the element does not match the type requested, or if index is out of range, they return 0 or NULL. Storage for the string returned by config_setting_get_string_elem is managed by the library and released automatically when the setting is destroyed or when its value is changed; the string must not be freed by the caller.

See also
SettingGetFloatElem, SettingGetInt64Elem, SettingGetIntElem, SettingGetStringElem

setting.GetConfig() As LcConfigC

TOP

addon - return the LcConfigC from the LcSettingC … → API: csmsgque.lcconfig.LcSettingC.GetConfig

reference for original

setting.GetElem(idx As Integer) As LcSettingC

TOP

This function fetches the element at the given index index in the setting setting, which must be an array, list, or group … → API: csmsgque.lcconfig.LcSettingC.GetElem

It returns the requested setting on success, or NULL if index is out of range or if setting is not an array, list, or group.

setting.GetFloat() As Double

TOP

These functions return the value of the given setting … → API: csmsgque.lcconfig.LcSettingC.GetFloat

If the type of the setting does not match the type requested, a 0 or NULL value is returned. Storage for the string returned by config_setting_get_string 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
SettingGetBool, SettingGetInt, SettingGetInt64, SettingGetString

setting.GetFloatElem(idx As Integer) As Double

TOP

These functions return the value at the specified index index in the setting setting … → API: csmsgque.lcconfig.LcSettingC.GetFloatElem

If the setting is not an array or list, or if the type of the element does not match the type requested, or if index is out of range, they return 0 or NULL. Storage for the string returned by config_setting_get_string_elem is managed by the library and released automatically when the setting is destroyed or when its value is changed; the string must not be freed by the caller.

See also
SettingGetBoolElem, SettingGetInt64Elem, SettingGetIntElem, SettingGetStringElem

setting.GetFormat() As LcConfigFormatE

TOP

These functions get and set the external format for the setting setting … → API: csmsgque.lcconfig.LcSettingC.GetFormat

The format must be one of the constants CONFIG_FORMAT_DEFAULT or CONFIG_FORMAT_HEX. All settings support the CONFIG_FORMAT_DEFAULT format. The CONFIG_FORMAT_HEX format specifies hexadecimal formatting for integer values, and hence only applies to settings of type CONFIG_TYPE_INT and CONFIG_TYPE_INT64. If format is invalid for the given setting, it is ignored.

If a non-default format has not been set for the setting, config_setting_get_format returns the default format for the configuration, as set by ConfigSetDefaultFormat.

config_setting_set_format returns CONFIG_TRUE on success and CONFIG_FALSE on failure.

See also
SettingSetFormat

setting.GetInt() As Integer

TOP

These functions return the value of the given setting … → API: csmsgque.lcconfig.LcSettingC.GetInt

If the type of the setting does not match the type requested, a 0 or NULL value is returned. Storage for the string returned by config_setting_get_string 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
SettingGetBool, SettingGetFloat, SettingGetInt64, SettingGetString

setting.GetInt64() As Long

TOP

These functions return the value of the given setting … → API: csmsgque.lcconfig.LcSettingC.GetInt64

If the type of the setting does not match the type requested, a 0 or NULL value is returned. Storage for the string returned by config_setting_get_string 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
SettingGetBool, SettingGetFloat, SettingGetInt, SettingGetString

setting.GetInt64Elem(idx As Integer) As Long

TOP

These functions return the value at the specified index index in the setting setting … → API: csmsgque.lcconfig.LcSettingC.GetInt64Elem

If the setting is not an array or list, or if the type of the element does not match the type requested, or if index is out of range, they return 0 or NULL. Storage for the string returned by config_setting_get_string_elem is managed by the library and released automatically when the setting is destroyed or when its value is changed; the string must not be freed by the caller.

See also
SettingGetBoolElem, SettingGetFloatElem, SettingGetIntElem, SettingGetStringElem

setting.GetIntElem(idx As Integer) As Integer

TOP

These functions return the value at the specified index index in the setting setting … → API: csmsgque.lcconfig.LcSettingC.GetIntElem

If the setting is not an array or list, or if the type of the element does not match the type requested, or if index is out of range, they return 0 or NULL. Storage for the string returned by config_setting_get_string_elem is managed by the library and released automatically when the setting is destroyed or when its value is changed; the string must not be freed by the caller.

See also
SettingGetBoolElem, SettingGetFloatElem, SettingGetInt64Elem, SettingGetStringElem

setting.GetMember(name As String) As LcSettingC

TOP

This function fetches the child setting named name from the group setting … → API: csmsgque.lcconfig.LcSettingC.GetMember

It returns the requested setting on success, or NULL if the setting was not found or if setting is not a group.

setting.GetString() As String

TOP

These functions return the value of the given setting … → API: csmsgque.lcconfig.LcSettingC.GetString

If the type of the setting does not match the type requested, a 0 or NULL value is returned. Storage for the string returned by config_setting_get_string 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
SettingGetBool, SettingGetFloat, SettingGetInt, SettingGetInt64

setting.GetStringElem(idx As Integer) As String

TOP

These functions return the value at the specified index index in the setting setting … → API: csmsgque.lcconfig.LcSettingC.GetStringElem

If the setting is not an array or list, or if the type of the element does not match the type requested, or if index is out of range, they return 0 or NULL. Storage for the string returned by config_setting_get_string_elem is managed by the library and released automatically when the setting is destroyed or when its value is changed; the string must not be freed by the caller.

See also
SettingGetBoolElem, SettingGetFloatElem, SettingGetInt64Elem, SettingGetIntElem

LcSettingC INTROSPECTION

C-API: LcSettingC_Introspection_C_API - Get information about all instances created by class

reference: MkObjectC_Introspection_C_API

[static] LcSettingC.Instances() As LcSettingC

TOP

get head-instance from linked-list of LcSettingS type … → API: csmsgque.lcconfig.LcSettingC.Instances

The head-instance is the last instance created.

reference for original

cfs.Next() As LcSettingC

TOP

get next instance from linked-list of LcSettingS type → API: csmsgque.lcconfig.LcSettingC.Next

reference for original

cfs.Prev() As LcSettingC

TOP

get previous instance from linked-list of LcSettingS type → API: csmsgque.lcconfig.LcSettingC.Prev

reference for original

LcSettingC IS

C-API: LcSettingC_Is_C_API - various functions to check the data-type from a LcSettingC

setting.IsAggregate() As Boolean

TOP

These convenience functions, some of which are implemented as macros, test if the setting setting is of an aggregate type (a group, array, or list), of a scalar type (integer, 64-bit integer, floating point, boolean, or string), and of a number (integer, 64-bit integer, or floating point), respectively … → API: csmsgque.lcconfig.LcSettingC.IsAggregate

They return CONFIG_TRUE or CONFIG_FALSE.

See also
SettingIsNumber, SettingIsScalar

setting.IsArray() As Boolean

TOP

These convenience functions, which are implemented as macros, test if the setting setting is of a given type … → API: csmsgque.lcconfig.LcSettingC.IsArray

They return CONFIG_TRUE or CONFIG_FALSE.

See also
SettingIsGroup, SettingIsList

setting.IsGroup() As Boolean

TOP

These convenience functions, which are implemented as macros, test if the setting setting is of a given type … → API: csmsgque.lcconfig.LcSettingC.IsGroup

They return CONFIG_TRUE or CONFIG_FALSE.

See also
SettingIsArray, SettingIsList

setting.IsList() As Boolean

TOP

These convenience functions, which are implemented as macros, test if the setting setting is of a given type … → API: csmsgque.lcconfig.LcSettingC.IsList

They return CONFIG_TRUE or CONFIG_FALSE.

See also
SettingIsArray, SettingIsGroup

setting.IsNumber() As Boolean

TOP

These convenience functions, some of which are implemented as macros, test if the setting setting is of an aggregate type (a group, array, or list), of a scalar type (integer, 64-bit integer, floating point, boolean, or string), and of a number (integer, 64-bit integer, or floating point), respectively … → API: csmsgque.lcconfig.LcSettingC.IsNumber

They return CONFIG_TRUE or CONFIG_FALSE.

See also
SettingIsAggregate, SettingIsScalar

setting.IsRoot() As Boolean

TOP

This function returns CONFIG_TRUE if the given setting is the root setting, and CONFIG_FALSE otherwise … → API: csmsgque.lcconfig.LcSettingC.IsRoot

setting.IsScalar() As Boolean

TOP

These convenience functions, some of which are implemented as macros, test if the setting setting is of an aggregate type (a group, array, or list), of a scalar type (integer, 64-bit integer, floating point, boolean, or string), and of a number (integer, 64-bit integer, or floating point), respectively … → API: csmsgque.lcconfig.LcSettingC.IsScalar

They return CONFIG_TRUE or CONFIG_FALSE.

See also
SettingIsAggregate, SettingIsNumber

LcSettingC LOOKUP

C-API: LcSettingC_Lookup_C_API - locates the setting in the configuration and return the data or an LcSettingC

In contrast to LcConfigC_Lookup_C_API, the path relative to the LcSettingC is used here.

setting.Lookup(path As String) As LcSettingC

TOP

This function locates a setting by a path path relative to the setting setting … → API: csmsgque.lcconfig.LcSettingC.Lookup

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

setting.LookupAll() As MkBufferListC

TOP

addon - read an entire configuration below setting into MkBufferListC … → API: csmsgque.lcconfig.LcSettingC.LookupAll

Returns
instand of MkBufferListC owned by setting.LookupAll() As MkBufferListC

reference for original

setting.LookupBool(name As String) As Boolean

TOP

These functions look up the value of the child setting named name of the setting setting … → API: csmsgque.lcconfig.LcSettingC.LookupBool

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 config_setting_lookup_string 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

setting.LookupFloat(name As String) As Double

TOP

These functions look up the value of the child setting named name of the setting setting … → API: csmsgque.lcconfig.LcSettingC.LookupFloat

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 config_setting_lookup_string 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

setting.LookupInt(name As String) As Integer

TOP

These functions look up the value of the child setting named name of the setting setting … → API: csmsgque.lcconfig.LcSettingC.LookupInt

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 config_setting_lookup_string 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

setting.LookupInt64(name As String) As Long

TOP

These functions look up the value of the child setting named name of the setting setting … → API: csmsgque.lcconfig.LcSettingC.LookupInt64

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 config_setting_lookup_string 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

setting.LookupString(name As String) As String

TOP

These functions look up the value of the child setting named name of the setting setting … → API: csmsgque.lcconfig.LcSettingC.LookupString

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 config_setting_lookup_string 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

LcSettingC MISC

C-API: LcSettingC_Misc_C_API - various functions to perform misc operationis on a LcSettingC

setting.AddIfNotExists(name As String, cfgtype As LcConfigTypeE) As LcSettingC

TOP

addon - add name with type only if not exists in the setting … → API: csmsgque.lcconfig.LcSettingC.AddIfNotExists

reference for original

setting.Exists(name As String) As Boolean

TOP

addon - return true if name exists in the setting otherwise false … → API: csmsgque.lcconfig.LcSettingC.Exists

reference for original

setting.Index() As Integer

TOP

This function returns the index of the given setting within its parent setting … → API: csmsgque.lcconfig.LcSettingC.Index

If setting is the root setting, this function returns -1.

setting.Length() As Integer

TOP

This function returns the number of settings in a group, or the number of elements in a list or array … → API: csmsgque.lcconfig.LcSettingC.Length

For other types of settings, it returns 0.

setting.Log(Optional fmtobj As MkObjectC = null, Optional debug As Integer = 0, Optional callfunc As String = FUNC, Optional lvl As Integer = 0)

TOP

log the setting … → API: csmsgque.lcconfig.LcSettingC.Log

Parameters
[in]mkrtthe MkRuntimeS instance to work on - the runtime argument, used by MK_RT_CALL (C-only)
[in]settingsame as config_setting_t
[in]fmtobjmanaged object used to format the log-message (default=NULL = use default format)
[in]debugthe debug level from MkRuntimeS::debug, use 0 <= debug <= 9 (default=0)
[in]callfunca user-defined postfix to identify the calling function or the environment (default=name-of-function)
[in]lvla user-defined prefix starting with "" for lvl=0 and increase with " " for lvl+1 (default=0)

setting.Name() As String

TOP

This function returns the name of the given setting, or NULL if the setting has no name … → API: csmsgque.lcconfig.LcSettingC.Name

Storage for the returned string is managed by the library and released automatically when the setting is destroyed; the string must not be freed by the caller.

setting.Parent() As LcSettingC

TOP

This function returns the parent setting of the given setting, or NULL if setting is the root setting … → API: csmsgque.lcconfig.LcSettingC.Parent

parent.Remove(name As String)

TOP

This function removes and destroys the setting named name from the parent setting parent, which must be a group … → API: csmsgque.lcconfig.LcSettingC.Remove

Any child settings of the setting are recursively destroyed as well.

The name parameter can also specify a setting path relative to the provided parent. (In that case, the setting will be looked up and removed.)

The function returns CONFIG_TRUE on success. If parent is not a group, or if it has no setting with the given name, it returns CONFIG_FALSE.

parent.RemoveElem(idx As Integer)

TOP

This function removes the child setting at the given index index from the setting parent, which must be a group, list, or array … → API: csmsgque.lcconfig.LcSettingC.RemoveElem

Any child settings of the removed setting are recursively destroyed as well.

The function returns CONFIG_TRUE on success. If parent is not a group, list, or array, or if index is out of range, it returns CONFIG_FALSE.

setting.SourceFile() As String

TOP

This function returns the name of the file from which the setting setting was read, or NULL if the setting was not read from a file … → API: csmsgque.lcconfig.LcSettingC.SourceFile

This information is useful for reporting application-level errors. Storage for the returned string is managed by the library and released automatically when the configuration is destroyed; the string must not be freed by the caller.

setting.SourceLine() As Integer

TOP

This function returns the line number of the configuration file or stream at which the setting setting was read, or 0 if no line number is available … → API: csmsgque.lcconfig.LcSettingC.SourceLine

This information is useful for reporting application-level errors.

setting.Type() As LcConfigTypeE

TOP

This function returns the type of the given setting … → API: csmsgque.lcconfig.LcSettingC.Type

The return value is one of the constants CONFIG_TYPE_INT, CONFIG_TYPE_INT64, CONFIG_TYPE_FLOAT, CONFIG_TYPE_STRING, CONFIG_TYPE_BOOL, CONFIG_TYPE_ARRAY, CONFIG_TYPE_LIST, or CONFIG_TYPE_GROUP.

LcSettingC SET

C-API: LcSettingC_Set_C_API - various functions to set data in a LcSettingC

Setting data is usefull to modify a configuration value on-the-fly or to setup an entire new configuration-file with ConfigWriteFile.

setting.SetBool(value As Boolean)

TOP

These functions set the value of the given setting to value … → API: csmsgque.lcconfig.LcSettingC.SetBool

On success, they return CONFIG_TRUE. If the setting does not match the type of the value, they return CONFIG_FALSE. config_setting_set_string makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetFloat, SettingSetInt, SettingSetInt64, SettingSetString

setting.SetBoolElem(idx As Integer, value As Integer) As LcSettingC

TOP

These functions set the value at the specified index index in the setting setting to value … → API: csmsgque.lcconfig.LcSettingC.SetBoolElem

If index is negative, a new element is added to the end of the array or list. On success, these functions return a pointer to the setting representing the element. If the setting is not an array or list, or if the setting is an array and the type of the array does not match the type of the value, or if index is out of range, they return NULL. config_setting_set_string_elem makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetFloatElem, SettingSetInt64Elem, SettingSetIntElem, SettingSetStringElem

setting.SetFloat(value As Double)

TOP

These functions set the value of the given setting to value … → API: csmsgque.lcconfig.LcSettingC.SetFloat

On success, they return CONFIG_TRUE. If the setting does not match the type of the value, they return CONFIG_FALSE. config_setting_set_string makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetBool, SettingSetInt, SettingSetInt64, SettingSetString

setting.SetFloatElem(idx As Integer, value As Double) As LcSettingC

TOP

These functions set the value at the specified index index in the setting setting to value … → API: csmsgque.lcconfig.LcSettingC.SetFloatElem

If index is negative, a new element is added to the end of the array or list. On success, these functions return a pointer to the setting representing the element. If the setting is not an array or list, or if the setting is an array and the type of the array does not match the type of the value, or if index is out of range, they return NULL. config_setting_set_string_elem makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetBoolElem, SettingSetInt64Elem, SettingSetIntElem, SettingSetStringElem

setting.SetFormat(format As LcConfigFormatE)

TOP

These functions get and set the external format for the setting setting … → API: csmsgque.lcconfig.LcSettingC.SetFormat

The format must be one of the constants CONFIG_FORMAT_DEFAULT or CONFIG_FORMAT_HEX. All settings support the CONFIG_FORMAT_DEFAULT format. The CONFIG_FORMAT_HEX format specifies hexadecimal formatting for integer values, and hence only applies to settings of type CONFIG_TYPE_INT and CONFIG_TYPE_INT64. If format is invalid for the given setting, it is ignored.

If a non-default format has not been set for the setting, config_setting_get_format returns the default format for the configuration, as set by ConfigSetDefaultFormat.

config_setting_set_format returns CONFIG_TRUE on success and CONFIG_FALSE on failure.

See also
SettingGetFormat

setting.SetInt(value As Integer)

TOP

These functions set the value of the given setting to value … → API: csmsgque.lcconfig.LcSettingC.SetInt

On success, they return CONFIG_TRUE. If the setting does not match the type of the value, they return CONFIG_FALSE. config_setting_set_string makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetBool, SettingSetFloat, SettingSetInt64, SettingSetString

setting.SetInt64(value As Long)

TOP

These functions set the value of the given setting to value … → API: csmsgque.lcconfig.LcSettingC.SetInt64

On success, they return CONFIG_TRUE. If the setting does not match the type of the value, they return CONFIG_FALSE. config_setting_set_string makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetBool, SettingSetFloat, SettingSetInt, SettingSetString

setting.SetInt64Elem(idx As Integer, value As Long) As LcSettingC

TOP

These functions set the value at the specified index index in the setting setting to value … → API: csmsgque.lcconfig.LcSettingC.SetInt64Elem

If index is negative, a new element is added to the end of the array or list. On success, these functions return a pointer to the setting representing the element. If the setting is not an array or list, or if the setting is an array and the type of the array does not match the type of the value, or if index is out of range, they return NULL. config_setting_set_string_elem makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetBoolElem, SettingSetFloatElem, SettingSetIntElem, SettingSetStringElem

setting.SetIntElem(idx As Integer, value As Integer) As LcSettingC

TOP

These functions set the value at the specified index index in the setting setting to value … → API: csmsgque.lcconfig.LcSettingC.SetIntElem

If index is negative, a new element is added to the end of the array or list. On success, these functions return a pointer to the setting representing the element. If the setting is not an array or list, or if the setting is an array and the type of the array does not match the type of the value, or if index is out of range, they return NULL. config_setting_set_string_elem makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetBoolElem, SettingSetFloatElem, SettingSetInt64Elem, SettingSetStringElem

setting.SetString(value As String)

TOP

These functions set the value of the given setting to value … → API: csmsgque.lcconfig.LcSettingC.SetString

On success, they return CONFIG_TRUE. If the setting does not match the type of the value, they return CONFIG_FALSE. config_setting_set_string makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetBool, SettingSetFloat, SettingSetInt, SettingSetInt64

setting.SetStringElem(idx As Integer, value As String) As LcSettingC

TOP

These functions set the value at the specified index index in the setting setting to value … → API: csmsgque.lcconfig.LcSettingC.SetStringElem

If index is negative, a new element is added to the end of the array or list. On success, these functions return a pointer to the setting representing the element. If the setting is not an array or list, or if the setting is an array and the type of the array does not match the type of the value, or if index is out of range, they return NULL. config_setting_set_string_elem makes a copy of the passed string value, so it may be subsequently freed or modified by the caller without affecting the value of the setting.

See also
SettingSetBoolElem, SettingSetFloatElem, SettingSetInt64Elem, SettingSetIntElem

LcSettingC TOR

C-API: LcSettingC_TOR_C_API - various functions to create, initialize and destroy a LcSettingC

A new LcSettingC is not created directly but is the return value of a "lookup".
The two functions:

need the unique path of the "setting" in the configuration file.

[static] LcSettingC.FromHandle(exporthdl As long) As LcSettingC

TOP

return a LcSettingC from exporthdl… → API: csmsgque.lcconfig.LcSettingC.FromHandle

reference for original

[constructor] parent.Add(name As String, __type As LcConfigTypeE)

TOP

This function adds a new child setting or element to the setting parent, which must be a group, array, or list … → API: csmsgque.lcconfig.LcSettingC.Add

If parent is an array or list, the name parameter is ignored and may be NULL.

The function returns the new setting on success, or NULL if parent is not a group, array, or list; or if there is already a child setting of parent named name; or if type is invalid. If type is a scalar type, the new setting will have a default value of 0, 0.0, false, or NULL, as appropriate.


EXAMPLES


SEE ALSO

liblcconfig, cclcconfig, cslcconfig, javalcconfig, golcconfig, pylcconfig, rubylcconfig, tcllcconfig, perllcconfig, phplcconfig

KEYWORDS

Vb.Net, unix, libconfig