formatter.h File Reference


Detailed Description

Common functions for commandline tools.

#include <dballe/core/error.h>

Go to the source code of this file.

Functions

dba_err dba_formatter_describe_level (int ltype, int l1, char **buf)
 Describe a level layer.
dba_err dba_formatter_describe_level_or_layer (int ltype1, int l1, int ltype2, int l2, char **buf)
 Describe a level or a layer.
dba_err dba_formatter_describe_trange (int ptype, int p1, int p2, char **buf)
 Describe a time range.


Function Documentation

dba_err dba_formatter_describe_level ( int  ltype,
int  l1,
char **  buf 
)

Describe a level layer.

Parameters:
ltype The level type
l1 The l1 value for the level
Return values:
buf The formatted layer description, on a newly allocated string. It is the responsibility of the caller to deallocate the string.
Returns:
The error indicator for the function (See error.h)

dba_err dba_formatter_describe_level_or_layer ( int  ltype1,
int  l1,
int  ltype2,
int  l2,
char **  buf 
)

Describe a level or a layer.

Parameters:
ltype1 The type of the first level
l1 The value of the first level
ltype2 The type of the second level
l2 The value of the second level
Return values:
buf The formatted layer description, on a newly allocated string. It is the responsibility of the caller to deallocate the string.
Returns:
The error indicator for the function (See error.h)

References DBA_RUN_OR_GOTO.

dba_err dba_formatter_describe_trange ( int  ptype,
int  p1,
int  p2,
char **  buf 
)

Describe a time range.

Parameters:
ptype The time range type
p1 The p1 value for the time range
p2 The p2 value for the time range
Return values:
buf The formatted time range description, on a newly allocated string. It is the responsibility of the caller to deallocate the string.
Returns:
The error indicator for the function (See error.h)


Generated on Fri Aug 8 14:15:56 2008 for libdballe by  doxygen 1.5.6