theKernel 10.0
Loading...
Searching...
No Matches
MkRuntimeC.cs
Go to the documentation of this file.
1
9/* LABEL-NO */
10using System;
11using System.Threading;
12using System.Reflection;
13using System.Runtime.InteropServices;
14using System.Runtime.CompilerServices;
15using Mk = csmkkernel.MkKernel;
16
17namespace csmkkernel {
18
22 public partial class MkRuntimeC : MkObjectC
23 {
24
31 public static void Reset() {
32 Mk.MkRuntimeSetCID(IntPtr.Zero);
33 }
34
35 } // END - class "MkRuntimeC"
36
37 // BEGIN-MkRuntimeC - created by 'cs_MqC.tcl -i NHI1_HOME/theKernel/c/gen/c_mkkernel.meta' - DO NOT change
38
39 public partial class MkRuntimeC {
40
44
45 // doc-key: MkRuntimeC,MkRuntimeC-Config,sm_
46
48 public static int DebugGet () {
49 Int32 __retVal__L = Mk.MkRuntimeDebugGet();
50 return __retVal__L;
51 }
52
54 public static void DebugSet (int dbg) {
55 Mk.MkRuntimeDebugSet(dbg);
56 }
57
59 public static MkErrorE ErrorGetCode () {
60 MkErrorE errVal = Mk.MkRuntimeErrorGetCode(IntPtr.Zero);
61 return errVal;
62 }
63
65 public static bool IsSilentGet () {
66 bool __retVal__L = Mk.MkRuntimeIsSilentGet();
67 return __retVal__L;
68 }
69
71 public static void IsSilentSet (bool silent) {
72 Mk.MkRuntimeIsSilentSet(IntPtr.Zero, silent);
73 }
74
76 public static string LogTargetGet () {
77 IntPtr __retVal__L = Mk.MkRuntimeLogTargetGet();
78 return Marshal.PtrToStringAnsi(__retVal__L);
79 }
80
82 public static void LogTargetReset () {
83 MkErrorE errVal = Mk.MkRuntimeLogTargetReset(IntPtr.Zero);
84 if (errVal > MkErrorE.CONTINUE) MkErrorC.Check(errVal);
85 }
86
88 public static void LogTargetSet (string logTgt) {
89 IntPtr logTgt_cstr = Marshal.StringToHGlobalAnsi(logTgt);
90 MkErrorE errVal = Mk.MkRuntimeLogTargetSet(IntPtr.Zero, logTgt_cstr);
91 Marshal.FreeHGlobal(logTgt_cstr);
92 if (errVal > MkErrorE.CONTINUE) MkErrorC.Check(errVal);
93 }
94
96 public static void NoDecoSet (bool noDeco) {
97 Mk.MkRuntimeNoDecoSet(IntPtr.Zero, noDeco);
98 }
99
101 // MkRuntimeC_Config_CS_API
102 }
103
104 public partial class MkRuntimeC {
105
109
110 // doc-key: MkRuntimeC,MkRuntimeC-Info,sm_
111
113 public static void Log0 (MkObjectC fmtobj = null, int debug = 0, [CallerMemberName]string callfunc = null, int lvl = 0) {
114 IntPtr fmtobj_hdl = MkObjectC.getOBJ_null_allow(fmtobj);
115 if (debug > (int)(MkRuntimeC.DebugGet())) {return;}
116 IntPtr callfunc_cstr = Marshal.StringToHGlobalAnsi(callfunc);
117 Mk.MkRuntimeLog0(IntPtr.Zero, fmtobj_hdl, debug, callfunc_cstr, lvl);
118 Marshal.FreeHGlobal(callfunc_cstr);
119 }
120
122 // MkRuntimeC_Info_CS_API
123 }
124
125 // END-MkRuntimeC - created by 'cs_MqC.tcl -i NHI1_HOME/theKernel/c/gen/c_mkkernel.meta' - DO NOT change
126
127// #################################################################################
128
129} // END - namespace "csmkkernel"
csmkkernel.MkKernel Mk
MkErrorC - the class known as err or error is used to create and manage an error message …
Definition MkErrorC.cs:498
static void Check(IntPtr ctx, MkErrorE err)
Definition MkErrorC.cs:74
MkKernel PACKAGE - The package is the toplevel structure of the Programming-Language-Micro-Kernel (PL...
MkObjectC - class known as obj or object is used as base-class type for a Programming-Language-Micro-...
static IntPtr getOBJ_null_allow(MkObjectC obj)
Definition MkObjectC.cs:116
MkRuntimeC - The class known as mkrt or runtime is the main csmkkernel application environment …
static void Reset()
Definition MkRuntimeC.cs:31
static MkErrorE MkRuntimeErrorGetCode(IntPtr mkrt)
static string LogTargetGet()
C#: [static] string MkRuntimeC.LogTargetGet() → C-API get the MkLogDataS::logNAME value …
Definition MkRuntimeC.cs:76
static void NoDecoSet(bool noDeco)
C#: [static] MkRuntimeC.NoDecoSet(bool noDeco) → C-API set the MkRuntimeS::noDeco value …
Definition MkRuntimeC.cs:96
static bool IsSilentGet()
C#: [static] bool MkRuntimeC.IsSilentGet() → C-API get the MkRuntimeS::isSilent value …
Definition MkRuntimeC.cs:65
static int DebugGet()
C#: [static] int MkRuntimeC.DebugGet() → C-API get the MkRuntimeS::debug value …
Definition MkRuntimeC.cs:48
static void LogTargetReset()
C#: [static] MkRuntimeC.LogTargetReset() → C-API set the MkRuntimeS::log value to the DEFAULT va...
Definition MkRuntimeC.cs:82
static void DebugSet(int dbg)
C#: [static] MkRuntimeC.DebugSet(int dbg) → C-API set the MkRuntimeS::debug value …
Definition MkRuntimeC.cs:54
static MkErrorE ErrorGetCode()
C#: [static] MkErrorE MkRuntimeC.ErrorGetCode() → C-API return MkErrorS.code from a given MkRunt...
Definition MkRuntimeC.cs:59
static void LogTargetSet(string logTgt)
C#: [static] MkRuntimeC.LogTargetSet(string logTgt) → C-API set the MkRuntimeS::log value and cl...
Definition MkRuntimeC.cs:88
static void IsSilentSet(bool silent)
C#: [static] MkRuntimeC.IsSilentSet(bool silent) → C-API set the MkRuntimeS::isSilent value …
Definition MkRuntimeC.cs:71
static void Log0(MkObjectC fmtobj=null, int debug=0, [CallerMemberName]string callfunc=null, int lvl=0)
C#: [static] MkRuntimeC.Log0(MkObjectC fmtobj = null, int debug = 0, [CallerMemberName]string callfun...
MkErrorE
→ C-API: MkErrorE → C-API: MkErrorE