theKernel 10.0
Loading...
Searching...
No Matches
MkErrorC_Raise_CS_API

MkErrorC - various functions to 'raise' a MkErrorSMore...

+ Collaboration diagram for MkErrorC_Raise_CS_API:

Functions

MkErrorC csmkkernel.MkErrorC.NoRaise ()
  C#: MkErrorC err.NoRaise() C-API
ignore the next return of MK_ERROR and do not raise an target-language-exception
 
void csmkkernel.MkErrorC.AppendC (string message)
  C#: err.AppendC(string message) C-API
append the message to the MkErrorS::text
 
void csmkkernel.MkErrorC.Raise ()
  C#: err.Raise() C-API
convert an csmkkernel error into an programming-language-error and raise afterwards. …
 
void csmkkernel.MkErrorC.SetC (string message, [CallerMemberName]string callfunc=null, int errnum=-1)
  C#: err.SetC(string message, [CallerMemberName]string callfunc = null, int errnum = -1) C-API
'set' and 'raise' the MkErrorC using a string-message and a errnum-number
 
static void csmkkernel.MkErrorC.PanicC (MkObjectC fmtobj, string callfunc, int errnum, string message)
  C#: [static] MkErrorC.PanicC(MkObjectC fmtobj, string callfunc, int errnum, string message) C-API
do a panic with string as argument …
 
static void csmkkernel.MkErrorC.PanicDEFAULT (MkObjectC fmtobj=null, [CallerMemberName]string callfunc=null)
  C#: [static] MkErrorC.PanicDEFAULT(MkObjectC fmtobj = null, [CallerMemberName]string callfunc = null) C-API
make panic from MkErrorDEFAULT_RT …
 

Detailed Description

MkErrorC - various functions to 'raise' a MkErrorS

An error is "raised" by naming the MkErrorS::text and changing the MkErrorS::code to MK_ERROR.

Function Documentation

◆ AppendC()

void csmkkernel.MkErrorC.AppendC ( string message)
inline

C#: err.AppendC(string message) C-API
append the message to the MkErrorS::text

Definition at line 341 of file MkErrorC.cs.

341 {
342 IntPtr message_cstr = Marshal.StringToHGlobalAnsi(message);
343 Mk.MkErrorAppendC(mkrt, hdl, message_cstr);
344 Marshal.FreeHGlobal(message_cstr);
345 }
csmkkernel.MkKernel Mk

◆ NoRaise()

MkErrorC csmkkernel.MkErrorC.NoRaise ( )
inline

C#: MkErrorC err.NoRaise() C-API
ignore the next return of MK_ERROR and do not raise an target-language-exception

Definition at line 333 of file MkErrorC.cs.

333 {
334 IntPtr __retVal__L = Mk.MkErrorNoRaise(mkrt, hdl);
335 return MkErrorC.MkErrorC_ObjNew(__retVal__L);
336 }

◆ PanicC()

static void csmkkernel.MkErrorC.PanicC ( MkObjectC fmtobj,
string callfunc,
int errnum,
string message )
inlinestatic

C#: [static] MkErrorC.PanicC(MkObjectC fmtobj, string callfunc, int errnum, string message) C-API
do a panic with string as argument …

Definition at line 366 of file MkErrorC.cs.

366 {
367 IntPtr fmtobj_hdl = MkObjectC.getOBJ_null_allow(fmtobj);
368 IntPtr callfunc_cstr = Marshal.StringToHGlobalAnsi(callfunc);
369 IntPtr message_cstr = Marshal.StringToHGlobalAnsi(message);
370 Mk.MkPanicC(IntPtr.Zero, fmtobj_hdl, callfunc_cstr, errnum, message_cstr);
371 Marshal.FreeHGlobal(callfunc_cstr);
372 Marshal.FreeHGlobal(message_cstr);
373 }
MkObjectC(IntPtr obj)
Definition MkObjectC.cs:121

◆ PanicDEFAULT()

static void csmkkernel.MkErrorC.PanicDEFAULT ( MkObjectC fmtobj = null,
[CallerMemberName] string callfunc = null )
inlinestatic

C#: [static] MkErrorC.PanicDEFAULT(MkObjectC fmtobj = null, [CallerMemberName]string callfunc = null) C-API
make panic from MkErrorDEFAULT_RT …

Definition at line 376 of file MkErrorC.cs.

376 {
377 IntPtr fmtobj_hdl = MkObjectC.getOBJ_null_allow(fmtobj);
378 IntPtr callfunc_cstr = Marshal.StringToHGlobalAnsi(callfunc);
379 Mk.MkPanicDEFAULT(IntPtr.Zero, fmtobj_hdl, callfunc_cstr);
380 Marshal.FreeHGlobal(callfunc_cstr);
381 }

◆ Raise()

void csmkkernel.MkErrorC.Raise ( )
inline

C#: err.Raise() C-API
convert an csmkkernel error into an programming-language-error and raise afterwards. …

Definition at line 348 of file MkErrorC.cs.

348 {
349 MkErrorE errVal = Mk.MkErrorRaise(mkrt, hdl);
350 MkErrorC.Check(hdl, errVal);
351 }
MkErrorE
collection for the different error-codes …

◆ SetC()

void csmkkernel.MkErrorC.SetC ( string message,
[CallerMemberName] string callfunc = null,
int errnum = -1 )
inline

C#: err.SetC(string message, [CallerMemberName]string callfunc = null, int errnum = -1) C-API
'set' and 'raise' the MkErrorC using a string-message and a errnum-number

Definition at line 354 of file MkErrorC.cs.

354 {
355 IntPtr message_cstr = Marshal.StringToHGlobalAnsi(message);
356 IntPtr callfunc_cstr = Marshal.StringToHGlobalAnsi(callfunc);
357 MkErrorE errVal = Mk.MkErrorSetC(mkrt, hdl, message_cstr, callfunc_cstr, errnum);
358 Marshal.FreeHGlobal(message_cstr);
359 Marshal.FreeHGlobal(callfunc_cstr);
360 MkErrorC.Check(hdl, errVal);
361 }
+ Here is the caller graph for this function: