LAL  7.2.0.1-a5e7375
LALError.h File Reference

Prototypes

int LALPrintError (const char *fmt,...)
 
int LALRaise (int sig, const char *fmt,...)
 
void LALAbort (const char *fmt,...)
 
int LALError (LALStatus *status, const char *statement)
 
int LALWarning (LALStatus *status, const char *warning)
 
int LALInfo (LALStatus *status, const char *info)
 
int LALTrace (LALStatus *status, int exitflg)
 
int LALInitStatus (LALStatus *status, const char *function, const char *id, const char *file, const int line)
 
int LALPrepareReturn (LALStatus *status, const char *file, const int line)
 
int LALAttatchStatusPtr (LALStatus *status, const char *file, const int line)
 
int LALDetatchStatusPtr (LALStatus *status, const char *file, const int line)
 
int LALPrepareAbort (LALStatus *status, const INT4 code, const char *mesg, const char *file, const int line)
 
int LALPrepareAssertFail (LALStatus *status, const INT4 code, const char *mesg, const char *statement, const char *file, const int line)
 
int LALCheckStatusPtr (LALStatus *status, const char *statement, const char *file, const int line)
 
int LAL_ERR_EXIT (LALStatus *, const char *func, const char *file, const int line, volatile const char *id)
 
int LAL_ERR_ABRT (LALStatus *, const char *func, const char *file, const int line, volatile const char *id)
 
int LAL_ERR_RTRN (LALStatus *, const char *func, const char *file, const int line, volatile const char *id)
 

Go to the source code of this file.

Macros

#define LALError(statusptr, statement)
 
#define LALWarning(statusptr, warning)
 
#define LALInfo(statusptr, info)
 
#define LALTrace(statusptr, exitflg)
 
#define LAL_ERR_DFLT   LAL_ERR_ABRT
 
#define LAL_CALL(function, statusptr)   ((function),lal_errhandler(statusptr,#function,__FILE__,__LINE__,"$Id$"))
 
#define LAL_FAIL_ERR   XLAL_EFAILED
 
#define LAL_FAIL_MSG   "operation failed"
 
#define LAL_NULL_ERR   XLAL_EFAULT
 
#define LAL_NULL_MSG   "unexpected NULL pointer"
 
#define LAL_NNULL_ERR   XLAL_EFAULT
 
#define LAL_NNULL_MSG   "unexpected non-NULL pointer"
 
#define LAL_NOMEM_ERR   XLAL_ENOMEM
 
#define LAL_NOMEM_MSG   "out of memory"
 
#define LAL_RANGE_ERR   XLAL_ERANGE
 
#define LAL_RANGE_MSG   "parameter out of range"
 
#define LAL_BADPARM_ERR   XLAL_EINVAL
 
#define LAL_BADPARM_MSG   "invalid parameter value"
 

Typedefs

typedef int(* lal_errhandler_t) (LALStatus *, const char *func, const char *file, const int line, volatile const char *id)
 

Variables

int(* lalRaiseHook )(int, const char *,...)
 
void(* lalAbortHook )(const char *,...)
 
lal_errhandler_t lal_errhandler
 

Macro Definition Documentation

◆ LALError

#define LALError (   statusptr,
  statement 
)
Value:
LALPrintError( "Error[%d] %d: function %s, file %s, line %d, %s\n" \
" %s %s\n", (statusptr)->level, (statusptr)->statusCode, \
(statusptr)->function, (statusptr)->file, (statusptr)->line, \
(statusptr)->Id, (statement), \
(statusptr)->statusDescription ) : 0 )
enable error messages
Definition: LALDebugLevel.h:44
#define lalDebugLevel
Definition: LALDebugLevel.h:56

Definition at line 104 of file LALError.h.

◆ LALWarning

#define LALWarning (   statusptr,
  warning 
)
Value:
LALPrintError( "Warning[%d]: function %s, file %s, line %d, %s\n" \
" %s\n", (statusptr)->level, (statusptr)->function, \
(statusptr)->file, (statusptr)->line, (statusptr)->Id, (warning) ) \
: 0 )
#define lalDebugLevel
Definition: LALDebugLevel.h:56
enable warning messages
Definition: LALDebugLevel.h:45

Definition at line 112 of file LALError.h.

◆ LALInfo

#define LALInfo (   statusptr,
  info 
)
Value:
LALPrintError( "Info[%d]: function %s, file %s, line %d, %s\n" \
" %s\n", (statusptr)->level, (statusptr)->function, \
(statusptr)->file, (statusptr)->line, (statusptr)->Id, (info) ) \
: 0 )
enable info messages
Definition: LALDebugLevel.h:46
#define lalDebugLevel
Definition: LALDebugLevel.h:56

Definition at line 119 of file LALError.h.

◆ LALTrace

#define LALTrace (   statusptr,
  exitflg 
)
Value:
LALPrintError( "%s[%d]: function %s, file %s, line %d, %s\n", \
(exitflg) ? "Leave" : "Enter", (statusptr)->level, \
(statusptr)->function, (statusptr)->file, (statusptr)->line, \
(statusptr)->Id ) \
: 0 )
enable tracing messages
Definition: LALDebugLevel.h:47
#define lalDebugLevel
Definition: LALDebugLevel.h:56

Definition at line 126 of file LALError.h.

◆ LAL_ERR_DFLT

#define LAL_ERR_DFLT   LAL_ERR_ABRT

Definition at line 150 of file LALError.h.

◆ LAL_CALL

#define LAL_CALL (   function,
  statusptr 
)    ((function),lal_errhandler(statusptr,#function,__FILE__,__LINE__,"$Id$"))

Definition at line 175 of file LALError.h.

◆ LAL_FAIL_ERR

#define LAL_FAIL_ERR   XLAL_EFAILED

Definition at line 184 of file LALError.h.

◆ LAL_FAIL_MSG

#define LAL_FAIL_MSG   "operation failed"

Definition at line 185 of file LALError.h.

◆ LAL_NULL_ERR

#define LAL_NULL_ERR   XLAL_EFAULT

Definition at line 186 of file LALError.h.

◆ LAL_NULL_MSG

#define LAL_NULL_MSG   "unexpected NULL pointer"

Definition at line 187 of file LALError.h.

◆ LAL_NNULL_ERR

#define LAL_NNULL_ERR   XLAL_EFAULT

Definition at line 188 of file LALError.h.

◆ LAL_NNULL_MSG

#define LAL_NNULL_MSG   "unexpected non-NULL pointer"

Definition at line 189 of file LALError.h.

◆ LAL_NOMEM_ERR

#define LAL_NOMEM_ERR   XLAL_ENOMEM

Definition at line 190 of file LALError.h.

◆ LAL_NOMEM_MSG

#define LAL_NOMEM_MSG   "out of memory"

Definition at line 191 of file LALError.h.

◆ LAL_RANGE_ERR

#define LAL_RANGE_ERR   XLAL_ERANGE

Definition at line 192 of file LALError.h.

◆ LAL_RANGE_MSG

#define LAL_RANGE_MSG   "parameter out of range"

Definition at line 193 of file LALError.h.

◆ LAL_BADPARM_ERR

#define LAL_BADPARM_ERR   XLAL_EINVAL

Definition at line 194 of file LALError.h.

◆ LAL_BADPARM_MSG

#define LAL_BADPARM_MSG   "invalid parameter value"

Definition at line 195 of file LALError.h.

Typedef Documentation

◆ lal_errhandler_t

typedef int( * lal_errhandler_t) (LALStatus *, const char *func, const char *file, const int line, volatile const char *id)

Definition at line 142 of file LALError.h.

Function Documentation

◆ LALInitStatus()

int LALInitStatus ( LALStatus status,
const char *  function,
const char *  id,
const char *  file,
const int  line 
)

Definition at line 159 of file LALError.c.

◆ LALPrepareReturn()

int LALPrepareReturn ( LALStatus status,
const char *  file,
const int  line 
)

Definition at line 192 of file LALError.c.

◆ LALAttatchStatusPtr()

int LALAttatchStatusPtr ( LALStatus status,
const char *  file,
const int  line 
)

Definition at line 210 of file LALError.c.

◆ LALDetatchStatusPtr()

int LALDetatchStatusPtr ( LALStatus status,
const char *  file,
const int  line 
)

Definition at line 235 of file LALError.c.

◆ LALPrepareAbort()

int LALPrepareAbort ( LALStatus status,
const INT4  code,
const char *  mesg,
const char *  file,
const int  line 
)

Definition at line 254 of file LALError.c.

◆ LALPrepareAssertFail()

int LALPrepareAssertFail ( LALStatus status,
const INT4  code,
const char *  mesg,
const char *  statement,
const char *  file,
const int  line 
)

Definition at line 274 of file LALError.c.

◆ LALCheckStatusPtr()

int LALCheckStatusPtr ( LALStatus status,
const char *  statement,
const char *  file,
const int  line 
)

Definition at line 295 of file LALError.c.

◆ LAL_ERR_EXIT()

int LAL_ERR_EXIT ( LALStatus ,
const char *  func,
const char *  file,
const int  line,
volatile const char *  id 
)

Definition at line 375 of file LALError.c.

◆ LAL_ERR_ABRT()

int LAL_ERR_ABRT ( LALStatus ,
const char *  func,
const char *  file,
const int  line,
volatile const char *  id 
)

Definition at line 391 of file LALError.c.

◆ LAL_ERR_RTRN()

int LAL_ERR_RTRN ( LALStatus ,
const char *  func,
const char *  file,
const int  line,
volatile const char *  id 
)

Definition at line 407 of file LALError.c.

Variable Documentation

◆ lalRaiseHook

int(* lalRaiseHook) (int, const char *,...)

Definition at line 57 of file LALError.c.

◆ lalAbortHook

void(* lalAbortHook) (const char *,...)

Definition at line 75 of file LALError.c.

◆ lal_errhandler

lal_errhandler_t lal_errhandler

Definition at line 373 of file LALError.c.