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

LcSettingC - various functions to perform misc operations … More...

+ Collaboration diagram for LcSettingC_Misc_TCL_API:

Functions

static OT_ProcRet tcllcconfig_LcSettingC_AddIfNotExists (LcSettingC_ARGS)
  Tcl: LcSettingC [$setting AddIfNotExists name:string cfgtype:LcConfigTypeE] C-API
addon - add name with type only if not exists in the setting
 
static OT_ProcRet tcllcconfig_LcSettingC_Parent (LcSettingC_ARGS)
  Tcl: LcSettingC [$setting Parent] C-API
This function returns the parent setting of the given setting, or NULL if setting is the root setting …
 
static OT_ProcRet tcllcconfig_LcSettingC_Exists (LcSettingC_ARGS)
  Tcl: bool [$setting Exists name:string] C-API
addon - return true if name exists in the setting otherwise false
 
static OT_ProcRet tcllcconfig_LcSettingC_Index (LcSettingC_ARGS)
  Tcl: int32 [$setting Index] C-API
This function returns the index of the given setting within its parent setting …
 
static OT_ProcRet tcllcconfig_LcSettingC_Length (LcSettingC_ARGS)
  Tcl: int32 [$setting Length] C-API
This function returns the number of settings in a group, or the number of elements in a list or array …
 
static OT_ProcRet tcllcconfig_LcSettingC_Name (LcSettingC_ARGS)
  Tcl: string [$setting Name] C-API
This function returns the name of the given setting, or NULL if the setting has no name …
 
static OT_ProcRet tcllcconfig_LcSettingC_Remove (LcSettingC_ARGS)
  Tcl: $parent Remove name:string C-API
This function removes and destroys the setting named name from the parent setting parent, which must be a group …
 
static OT_ProcRet tcllcconfig_LcSettingC_RemoveElem (LcSettingC_ARGS)
  Tcl: $parent RemoveElem idx:int32 C-API
This function removes the child setting at the given index index from the setting parent, which must be a group, list, or array …
 
static OT_ProcRet tcllcconfig_LcSettingC_SourceFile (LcSettingC_ARGS)
  Tcl: string [$setting SourceFile] C-API
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 …
 
static OT_ProcRet tcllcconfig_LcSettingC_SourceLine (LcSettingC_ARGS)
  Tcl: int32 [$setting SourceLine] C-API
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 …
 
static OT_ProcRet tcllcconfig_LcSettingC_Type (LcSettingC_ARGS)
  Tcl: LcConfigTypeE [$setting Type] C-API
This function returns the type of the given setting
 

Detailed Description

LcSettingC - various functions to perform misc operations …

Function Documentation

◆ tcllcconfig_LcSettingC_AddIfNotExists()

static OT_ProcRet tcllcconfig_LcSettingC_AddIfNotExists ( LcSettingC_ARGS )
static

Tcl: LcSettingC [$setting AddIfNotExists name:string cfgtype:LcConfigTypeE] C-API
addon - add name with type only if not exists in the setting

Definition at line 739 of file LcSettingC_tcl.c.

739 {
741 OT_SETUP_VARARGS(2,2,AddIfNotExists_doc)
742 MK_STRN name = 0;
743 OT_CHECK_REQUIRED(OT_CHECK_STRN (name))
744 enum LcConfigTypeE cfgtype = 0;
745 OT_CHECK_REQUIRED(OT_CHECK_ENUM (LcConfigTypeE,cfgtype))
746 OT_CHECK_NOARGS
747 LC_CFS retVal = LcSettingAddIfNotExists (hdl, name, cfgtype);
748 OT_retObj_SET_CFS(retVal)
749 goto end;
750 error:
751 OT_retObj_SET_Error
752 end:
753 OT_retObj_RETURN
754}
#define OT_SETUP_hdl
#define AddIfNotExists_doc
LcConfigTypeE
define the data-type of a LcSettingC …
Definition LcEnum_lc.h:81
static LC_CFS LcSettingAddIfNotExists(LC_CFS setting, MK_STRN name, enum LcConfigTypeE cfgtype)
addon - add name with type only if not exists in the setting …
const MK_STRB * MK_STRN
Struct to represent the data from the LcSettingC …

◆ tcllcconfig_LcSettingC_Exists()

static OT_ProcRet tcllcconfig_LcSettingC_Exists ( LcSettingC_ARGS )
static

Tcl: bool [$setting Exists name:string] C-API
addon - return true if name exists in the setting otherwise false

Definition at line 777 of file LcSettingC_tcl.c.

777 {
779 OT_SETUP_ONEARG(Exists_doc)
780 MK_STRN name = 0;
781 OT_CHECK_REQUIRED(OT_CHECK_STRN (name))
782 OT_CHECK_NOARGS
783 OT_retObj_SET_BOL(LcSettingExists (hdl, name))
784 goto end;
785 error:
786 OT_retObj_SET_Error
787 end:
788 OT_retObj_RETURN
789}
#define Exists_doc
static bool LcSettingExists(const LC_CFS setting, MK_STRN name)
addon - return true if name exists in the setting otherwise false …

◆ tcllcconfig_LcSettingC_Index()

static OT_ProcRet tcllcconfig_LcSettingC_Index ( LcSettingC_ARGS )
static

Tcl: int32 [$setting Index] C-API
This function returns the index of the given setting within its parent setting …

Definition at line 792 of file LcSettingC_tcl.c.

792 {
794 OT_SETUP_NOARG(Index_doc)
795 OT_CHECK_NOARGS
796 OT_retObj_SET_I32(LcSettingIndex (hdl))
797 goto end;
798 error:
799 OT_retObj_SET_Error
800 end:
801 OT_retObj_RETURN
802}
#define Index_doc
static MK_I32 LcSettingIndex(LC_CFSN setting)
This function returns the index of the given setting within its parent setting …

◆ tcllcconfig_LcSettingC_Length()

static OT_ProcRet tcllcconfig_LcSettingC_Length ( LcSettingC_ARGS )
static

Tcl: int32 [$setting Length] C-API
This function returns the number of settings in a group, or the number of elements in a list or array …

Definition at line 805 of file LcSettingC_tcl.c.

805 {
807 OT_SETUP_NOARG(Length_doc)
808 OT_CHECK_NOARGS
809 OT_retObj_SET_I32(LcSettingLength (hdl))
810 goto end;
811 error:
812 OT_retObj_SET_Error
813 end:
814 OT_retObj_RETURN
815}
#define Length_doc
static MK_I32 LcSettingLength(LC_CFSN setting)
This function returns the number of settings in a group, or the number of elements in a list or array...

◆ tcllcconfig_LcSettingC_Name()

static OT_ProcRet tcllcconfig_LcSettingC_Name ( LcSettingC_ARGS )
static

Tcl: string [$setting Name] C-API
This function returns the name of the given setting, or NULL if the setting has no name …

Definition at line 820 of file LcSettingC_tcl.c.

820 {
822 OT_SETUP_NOARG(Name_doc)
823 OT_CHECK_NOARGS
824 OT_retObj_SET_STR(LcSettingName (hdl))
825 goto end;
826 error:
827 OT_retObj_SET_Error
828 end:
829 OT_retObj_RETURN
830}
#define Name_doc
static MK_STRN LcSettingName(LC_CFSN setting)
This function returns the name of the given setting, or NULL if the setting has no name …

◆ tcllcconfig_LcSettingC_Parent()

static OT_ProcRet tcllcconfig_LcSettingC_Parent ( LcSettingC_ARGS )
static

Tcl: LcSettingC [$setting Parent] C-API
This function returns the parent setting of the given setting, or NULL if setting is the root setting …

Definition at line 757 of file LcSettingC_tcl.c.

757 {
759 OT_SETUP_NOARG(Parent_doc)
760 OT_CHECK_NOARGS
761 LC_CFS retVal = LcSettingParent (hdl);
762 if (retVal == NULL) {
763 OT_ERROR_SOFT_CONSTRUCTOR(LcSettingC)
764 goto error;
765 }
766 OT_retObj_SET_CFS(retVal)
767 goto end;
768 error:
769 OT_retObj_SET_Error
770 end:
771 OT_retObj_RETURN
772}
#define Parent_doc
static LC_CFS LcSettingParent(LC_CFSN setting)
This function returns the parent setting of the given setting, or NULL if setting is the root setting...

◆ tcllcconfig_LcSettingC_Remove()

static OT_ProcRet tcllcconfig_LcSettingC_Remove ( LcSettingC_ARGS )
static

Tcl: $parent Remove name:string C-API
This function removes and destroys the setting named name from the parent setting parent, which must be a group …

Definition at line 833 of file LcSettingC_tcl.c.

833 {
835 OT_SETUP_ONEARG(Remove_doc)
836 MK_STRN name = 0;
837 OT_CHECK_REQUIRED(OT_CHECK_STRN (name))
838 OT_CHECK_NOARGS
839 MkErrorC_Check(hdl,LcSettingRemove (hdl, name));
840 OT_retObj_SET_None
841 goto end;
842 error:
843 OT_retObj_SET_Error
844 end:
845 OT_retObj_RETURN
846}
#define Remove_doc
static enum MkErrorE LcSettingRemove(LC_CFS parent, MK_STRN name)
This function removes and destroys the setting named name from the parent setting parent,...

◆ tcllcconfig_LcSettingC_RemoveElem()

static OT_ProcRet tcllcconfig_LcSettingC_RemoveElem ( LcSettingC_ARGS )
static

Tcl: $parent RemoveElem idx:int32 C-API
This function removes the child setting at the given index index from the setting parent, which must be a group, list, or array …

Definition at line 849 of file LcSettingC_tcl.c.

849 {
851 OT_SETUP_ONEARG(RemoveElem_doc)
852 MK_I32 idx = 0;
853 OT_CHECK_REQUIRED(OT_CHECK_NI4 (idx))
854 OT_CHECK_NOARGS
855 MkErrorC_Check(hdl,LcSettingRemoveElem (hdl, idx));
856 OT_retObj_SET_None
857 goto end;
858 error:
859 OT_retObj_SET_Error
860 end:
861 OT_retObj_RETURN
862}
#define RemoveElem_doc
static enum MkErrorE LcSettingRemoveElem(LC_CFS parent, MK_I32 idx)
This function removes the child setting at the given index index from the setting parent,...
signed int MK_I32

◆ tcllcconfig_LcSettingC_SourceFile()

static OT_ProcRet tcllcconfig_LcSettingC_SourceFile ( LcSettingC_ARGS )
static

Tcl: string [$setting SourceFile] C-API
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 …

Definition at line 865 of file LcSettingC_tcl.c.

865 {
867 OT_SETUP_NOARG(SourceFile_doc)
868 OT_CHECK_NOARGS
869 OT_retObj_SET_STR(LcSettingSourceFile (hdl))
870 goto end;
871 error:
872 OT_retObj_SET_Error
873 end:
874 OT_retObj_RETURN
875}
#define SourceFile_doc
static MK_STRN LcSettingSourceFile(LC_CFSN setting)
This function returns the name of the file from which the setting setting was read,...

◆ tcllcconfig_LcSettingC_SourceLine()

static OT_ProcRet tcllcconfig_LcSettingC_SourceLine ( LcSettingC_ARGS )
static

Tcl: int32 [$setting SourceLine] C-API
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 …

Definition at line 878 of file LcSettingC_tcl.c.

878 {
880 OT_SETUP_NOARG(SourceLine_doc)
881 OT_CHECK_NOARGS
882 OT_retObj_SET_I32(LcSettingSourceLine (hdl))
883 goto end;
884 error:
885 OT_retObj_SET_Error
886 end:
887 OT_retObj_RETURN
888}
#define SourceLine_doc
static MK_I32 LcSettingSourceLine(LC_CFSN setting)
This function returns the line number of the configuration file or stream at which the setting settin...

◆ tcllcconfig_LcSettingC_Type()

static OT_ProcRet tcllcconfig_LcSettingC_Type ( LcSettingC_ARGS )
static

Tcl: LcConfigTypeE [$setting Type] C-API
This function returns the type of the given setting

Definition at line 891 of file LcSettingC_tcl.c.

891 {
893 OT_SETUP_NOARG(Type_doc)
894 OT_CHECK_NOARGS
895 OT_retObj_SET(OT_NEW_Lc_enum_OBJ(ConfigTypeE,LcSettingType (hdl)))
896 goto end;
897 error:
898 OT_retObj_SET_Error
899 end:
900 OT_retObj_RETURN
901}
#define Type_doc
static enum LcConfigTypeE LcSettingType(LC_CFSN setting)
This function returns the type of the given setting …