libsyncml  0.5.4
Functions

Libsyncml's error reporting facilities. More...

Collaboration diagram for SyncML Errors:

Functions

SmlError ** smlErrorRef (SmlError **error)
 
void smlErrorDeref (SmlError **error)
 
SmlBool smlErrorIsSet (SmlError **error)
 Checks if the error is set. More...
 
SmlErrorType smlErrorGetType (SmlError **error)
 Returns the type of the error. More...
 
const char * smlErrorPrint (SmlError **error)
 Returns the message of the error. More...
 
void smlErrorUpdate (SmlError **error, const char *format,...)
 Updates the error message. More...
 
void smlErrorDuplicate (SmlError **target, SmlError **source)
 Duplicates the error into the target. More...
 
void smlErrorSet (SmlError **error, SmlErrorType type, const char *format,...)
 Sets the error. More...
 
void smlErrorSetType (SmlError **error, SmlErrorType type)
 Sets the type of an error. More...
 
SmlErrorClass smlErrorGetClass (SmlError **error)
 Gets the error class. More...
 

Detailed Description

Libsyncml's error reporting facilities.

Function Documentation

SmlBool smlErrorIsSet ( SmlError **  error)

Checks if the error is set.

Parameters
errorA pointer to a error struct to check
Returns
TRUE if the error is set, FALSE otherwise

Definition at line 268 of file sml_error.c.

Referenced by smlErrorDuplicate(), smlErrorGetClass(), smlErrorGetType(), smlErrorPrint(), smlErrorSetVargs(), and smlErrorUpdate().

SmlErrorType smlErrorGetType ( SmlError **  error)

Returns the type of the error.

Parameters
errorThe error
Returns
The type of the error

Definition at line 285 of file sml_error.c.

Here is the call graph for this function:

const char* smlErrorPrint ( SmlError **  error)
void smlErrorUpdate ( SmlError **  error,
const char *  format,
  ... 
)

Updates the error message.

You can use this function to update the error message on a error. You can use the old error->message as a parameter for this function.

Parameters
errorA pointer to a error struct to update
formatThe new message

Definition at line 317 of file sml_error.c.

Here is the call graph for this function:

void smlErrorDuplicate ( SmlError **  target,
SmlError **  source 
)

Duplicates the error into the target.

Parameters
targetThe target error to update
sourceThe source error which to duplicate

Definition at line 337 of file sml_error.c.

Referenced by smlManagerStop().

Here is the call graph for this function:

void smlErrorSet ( SmlError **  error,
SmlErrorType  type,
const char *  format,
  ... 
)
void smlErrorSetType ( SmlError **  error,
SmlErrorType  type 
)

Sets the type of an error.

Parameters
errorA pointer to a error struct to set
typeThe Error type to set

Definition at line 369 of file sml_error.c.

SmlErrorClass smlErrorGetClass ( SmlError **  error)

Gets the error class.

Parameters
errorA pointer to a error struct
Returns
The error class

Definition at line 382 of file sml_error.c.

Here is the call graph for this function: