theKernel 10.0
Loading...
Searching...
No Matches
MkErrorC_Misc_PY_API

MkErrorC - various functions to 'work' on a MkErrorSMore...

+ Collaboration diagram for MkErrorC_Misc_PY_API:

Functions

static OT_ProcRet pymkkernel_MkErrorC_Catch (MkErrorC_ARGS)
  Python: MkErrorC err.Catch(?exception:errorCode=None?, ?callfunc:string="MK_NULL"?) C-API
convert a programming-language-error into an pymkkernel error …
 
static OT_ProcRet pymkkernel_MkErrorC_Cleanup (MkErrorC_ARGS)
  Python: err.Cleanup(?callfunc:string="MK_NULL"?, ?callline:int32=-1?) C-API
cleanup and print unwanted active error …
 
MK_DEPRECATED static MK_UNUSED OT_ProcRet pymkkernel_MkErrorC_Log (MkErrorC_ARGS)
 
static OT_ProcRet pymkkernel_MkErrorC_Println (MkErrorC_ARGS)
  Python: err.Println(?msg:string=""?, ?callfunc:string="MK_NULL"?, ?callline:int32=-1?) C-API
print the default-error to the MkLogFileC (default: stderr) and clear the error afterwards …
 
static OT_ProcRet pymkkernel_MkErrorC_Reset (MkErrorC_ARGS)
  Python: err.Reset(?callfunc:string="MK_NULL"?, ?callline:int32=-1?, ?force:bool=false?) C-API
This function clears the err and resets to MK_OK
 
static OT_ProcRet pymkkernel_MkErrorC_Stack (MkErrorC_ARGS)
  Python: MkErrorE err.Stack(?callfunc:string="MK_NULL"?, ?callfile:string="MK_NULL"?, ?callline:int32=-1?) C-API
check on error and if yes append an ErrorStackFormat to the error-message
 
static OT_ProcRet pymkkernel_MkErrorC_StackFormat (MkErrorC_ARGS)
  Python: err.StackFormat(?callfunc:string="MK_NULL"?, ?callfile:string="MK_NULL"?, ?callline:int32=-1?) C-API
append an ensemble of func, file and line to the error-message
 
MK_DEPRECATED static MK_UNUSED OT_ProcRet pymkkernel_MkErrorC_ToString (MkErrorC_ARGS)
 

Detailed Description

MkErrorC - various functions to 'work' on a MkErrorS

Function Documentation

◆ pymkkernel_MkErrorC_Catch()

static OT_ProcRet pymkkernel_MkErrorC_Catch ( MkErrorC_ARGS )
static

Python: MkErrorC err.Catch(?exception:errorCode=None?, ?callfunc:string="MK_NULL"?) C-API
convert a programming-language-error into an pymkkernel error …

Definition at line 389 of file MkErrorC_py.c.

389 {
392 MK_EXP exception = NULL;
394 MK_STRN callfunc = NULL;
397 if (MkSysStringIsNULL(callfunc)) {callfunc = OT_GET_CALL_PROC;}
398 MK_ERR retVal = MkErrorCatchTmpl (hdl, exception, callfunc);
399 OT_retObj_SET_ERR(retVal);
400 goto end;
401 error:
403 end:
406}
#define OT_SETUP_VARARGS(min, max, d)
#define OT_retObj_SET_Error
#define OT_FRAME_CLEANUP
#define OT_retObj_RETURN
#define OT_GET_CALL_PROC
#define OT_CHECK_OPTIONAL(val)
#define OT_retObj_SET_ERR(nat)
#define OT_CHECK_NOARGS
#define OT_CHECK_STRN(val)
#define OT_SETUP_hdl
Definition MkErrorC_py.c:23
#define Catch_doc
#define MkErrorCatchTmpl(...)
Definition MkErrorC_py.c:98
const MK_STRB * MK_STRN
constant string pointer data-type
MK_PTRB const * MK_EXP
exception object pointer
static bool MkSysStringIsNULL(MK_STRN str)
test if string is NULL or EMPTY …
#define OT_CHECK_EXP(val)
The data-type to store and handle the error-condition …

◆ pymkkernel_MkErrorC_Cleanup()

static OT_ProcRet pymkkernel_MkErrorC_Cleanup ( MkErrorC_ARGS )
static

Python: err.Cleanup(?callfunc:string="MK_NULL"?, ?callline:int32=-1?) C-API
cleanup and print unwanted active error …

Definition at line 411 of file MkErrorC_py.c.

411 {
414 MK_STRN callfunc = NULL;
416 MK_I32 callline = -1;
419 if (callline == -1 ) {callline = OT_GET_CALL_LINE;}
420 if (MkSysStringIsNULL(callfunc)) {callfunc = OT_GET_CALL_PROC;}
421 MkErrorCleanup (hdl, callfunc, callline);
423 goto end;
424 error:
426 end:
429}
#define OT_CHECK_NI4(val)
#define OT_GET_CALL_LINE
#define OT_retObj_SET_None
#define Cleanup_doc
#define MkErrorCleanup(...)
signed int MK_I32
4 byte integer data-type

◆ pymkkernel_MkErrorC_Log()

MK_DEPRECATED static MK_UNUSED OT_ProcRet pymkkernel_MkErrorC_Log ( MkErrorC_ARGS )
static

Definition at line 433 of file MkErrorC_py.c.

#define OT_ERROR_LNG_RETURN

◆ pymkkernel_MkErrorC_Println()

static OT_ProcRet pymkkernel_MkErrorC_Println ( MkErrorC_ARGS )
static

Python: err.Println(?msg:string=""?, ?callfunc:string="MK_NULL"?, ?callline:int32=-1?) C-API
print the default-error to the MkLogFileC (default: stderr) and clear the error afterwards …

Definition at line 436 of file MkErrorC_py.c.

436 {
439 MK_STRN msg = "";
441 MK_STRN callfunc = NULL;
443 MK_I32 callline = -1;
446 if (callline == -1 ) {callline = OT_GET_CALL_LINE;}
447 if (MkSysStringIsNULL(callfunc)) {callfunc = OT_GET_CALL_PROC;}
448 MkErrorPrintln (hdl, msg, callfunc, callline);
450 goto end;
451 error:
453 end:
456}
#define Println_doc
#define MkErrorPrintln(...)

◆ pymkkernel_MkErrorC_Reset()

static OT_ProcRet pymkkernel_MkErrorC_Reset ( MkErrorC_ARGS )
static

Python: err.Reset(?callfunc:string="MK_NULL"?, ?callline:int32=-1?, ?force:bool=false?) C-API
This function clears the err and resets to MK_OK

Definition at line 459 of file MkErrorC_py.c.

459 {
462 MK_STRN callfunc = NULL;
464 MK_I32 callline = -1;
466 MK_BOOL force = false;
469 if (callline == -1 ) {callline = OT_GET_CALL_LINE;}
470 if (MkSysStringIsNULL(callfunc)) {callfunc = OT_GET_CALL_PROC;}
471 MkErrorC_Check(hdl,MkErrorReset (hdl, callfunc, callline, force));
473 goto end;
474 error:
476 end:
479}
#define OT_CHECK_bool(val)
#define MkErrorC_Check(mng, PROC)
#define Reset_doc
#define MkErrorReset(...)
bool MK_BOOL
real bool data-type

◆ pymkkernel_MkErrorC_Stack()

static OT_ProcRet pymkkernel_MkErrorC_Stack ( MkErrorC_ARGS )
static

Python: MkErrorE err.Stack(?callfunc:string="MK_NULL"?, ?callfile:string="MK_NULL"?, ?callline:int32=-1?) C-API
check on error and if yes append an ErrorStackFormat to the error-message

Definition at line 482 of file MkErrorC_py.c.

482 {
485 MK_STRN callfunc = NULL;
487 MK_STRN callfile = NULL;
489 MK_I32 callline = -1;
492 if (callline == -1 ) {callline = OT_GET_CALL_LINE;}
493 if (MkSysStringIsNULL(callfile)) {callfile = OT_GET_CALL_FILE;}
494 if (MkSysStringIsNULL(callfunc)) {callfunc = OT_GET_CALL_PROC;}
495 OT_retObj_SET(OT_NEW_Mk_enum_OBJ(ErrorE,MkErrorStack (hdl, callfunc, callfile, callline)));
496 goto end;
497 error:
499 end:
502}
#define OT_GET_CALL_FILE
#define OT_NEW_Mk_enum_OBJ(typ, val)
#define OT_retObj_SET(val)
#define Stack_doc
#define OT_SETUP_hdl__null_allow
Definition MkErrorC_py.c:24
#define MkErrorStack(...)

◆ pymkkernel_MkErrorC_StackFormat()

static OT_ProcRet pymkkernel_MkErrorC_StackFormat ( MkErrorC_ARGS )
static

Python: err.StackFormat(?callfunc:string="MK_NULL"?, ?callfile:string="MK_NULL"?, ?callline:int32=-1?) C-API
append an ensemble of func, file and line to the error-message

Definition at line 505 of file MkErrorC_py.c.

505 {
508 MK_STRN callfunc = NULL;
510 MK_STRN callfile = NULL;
512 MK_I32 callline = -1;
515 if (callline == -1 ) {callline = OT_GET_CALL_LINE;}
516 if (MkSysStringIsNULL(callfile)) {callfile = OT_GET_CALL_FILE;}
517 if (MkSysStringIsNULL(callfunc)) {callfunc = OT_GET_CALL_PROC;}
518 MkErrorStackFormat (hdl, callfunc, callfile, callline);
520 goto end;
521 error:
523 end:
526}
#define StackFormat_doc
#define MkErrorStackFormat(...)

◆ pymkkernel_MkErrorC_ToString()

MK_DEPRECATED static MK_UNUSED OT_ProcRet pymkkernel_MkErrorC_ToString ( MkErrorC_ARGS )
static

Definition at line 530 of file MkErrorC_py.c.