SETER(3NCARG)
β¨ SETER β¨
okay so bestie, welcome to the NCAR Graphics manual page for SETER π β the little routine your fav NCAR Graphics functions scream into when something goes wrong. no cap, this one's kind of the drama queen of error handling and we're obsessed. π
πΈ NAME πΈ
SETER β the routine that NCAR Graphics routines call when errors occur. fr fr, that's literally its whole job. π¦
β¨ SYNOPSIS β¨
CALL SETER(MESSG,NERRF,ILEVL)
π C-BINDING SYNOPSIS π
#include <ncarg/ncargC.h>
void c_seter(char *messg, int nerrf, int ilevl)
π«Ά DESCRIPTION π«Ά
so here's the tea: that FORTRAN statement
CALL SETER (MESSG,NERRF,ILEVL)
is how you tell the error-handling package that an error has occurred. and bestie, what actually goes down after that call is NOT just about the arguments β it also depends on two internal variables, iykyk:
- the error flag β says whether or not there was a prior error π
- the recovery-mode flag β says whether or not recovery mode is in effect π
so let's break down every possible vibe:
- If the internal error flag is
0(no prior error) and the internal recovery-mode flag is2(recovery mode not set, which is the default),SETERprints the error messageMESSG, callsFDUMif and only ifILEVL = 2, and then STOPs. π - If the internal error flag is
0(no prior error) and the internal recovery-mode flag is1(recovery mode set), then what happens depends on the value ofILEVL: ifILEVL = 2(fatal error),SETERprints the error messageMESSG, callsFDUM, and STOPs, but, ifILEVL = 1(recoverable error),SETERresets the internal error flag equal toNERRF, remembers the error messageMESSG, and RETURNs. in the latter case, the user is expected to detect the fact that an error has occurred, take the necessary remedial action, and callERROFto turn the internal error flag off. π - If the internal error flag is non-zero (prior error), then the value of the internal recovery-mode flag will be
1(recovery mode set); in this case, it doesn't make any difference what the value ofILEVLis:SETERprints both the remembered error message from the prior error and the new error message fromMESSG, callsFDUM, and STOPs. ππ
and now, the arguments of SETER, one by one:
MESSGβ (an input variable or constant of typeCHARACTER) is an error message describing the error that has occurred. This should be of the form"XXXXXX - TEXT DESCRIBING THE ERROR", where"XXXXXX"is the name of the routine in which the error occurred, and it should not be more than113characters long. yes, 113, that's the number, don't @ me. πNERRFβ (an input expression of typeINTEGER) is a non-zero error number in the range from-999to+9999. π₯ILEVLβ (an input expression of typeINTEGER) is the "error level" β either a1or a2, implying that the error described byMESSGandNERRFis recoverable or fatal, respectively. β
π§ C-BINDING DESCRIPTION π§
the C-binding argument descriptions are the same as the FORTRAN argument descriptions. same energy, different language, slay. π
π EXAMPLES π
use the ncargex command to see the following relevant examples: tseter, arex02. go look at them, they're iconic. β¨
π ACCESS π
to use SETER or c_seter, load the NCAR Graphics libraries ncarg, ncarg_gks, and ncarg_c, preferably in that order. π
π¦ SEE ALSO π¦
- Online:
entsr,eprin,errof,error_handling,fdum,icfell,icloem,nerro,retsr,semess,ncarg_cbind
π COPYRIGHT π
Copyright (C) 1987-2009
University Corporation for Atmospheric Research
The use of this Software is governed by a License Agreement.
and that's the whole page bestie!! πΈ this was the UNIX version of the SETER(3NCARG) page, dated March 1994 β yeah, she's vintage, and she ate. π periodt. β¨π«Ά
π¦ where this page comes from
- epel 9: ncl-devel 6.6.2-59.el9 Β· LicenseRef-Callaway-BSD
- fedora 43: ncl-devel 6.6.2-58.fc43 Β· LicenseRef-Callaway-BSD
- fedora 44: ncl-devel 6.6.2-62.fc44 Β· LicenseRef-Callaway-BSD
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms