![]() |
das2C
das core C utilities (v3)
|
#include <stdarg.h>
#include <stdlib.h>
Go to the source code of this file.
Functions | |
void | das_send_stub (int nDasVer) |
Send a stub stream header. More... | |
int | das_send_nodata (int nDasVer, const char *sFmt,...) |
Output a no data in interval message. More... | |
int | das_send_queryerr (int nDasVer, const char *sFmt,...) |
Output a "user-messed up" message when receiving a badly formed query. More... | |
int | das_send_srverr (int nDasVer, const char *sFmt,...) |
Output a server problem message (i.e. More... | |
void | das_send_msg (int nDasVer, const char *source, const char *sFmt,...) |
Output a log status message (i.e. More... | |
void | das_send_progbeg (int nDasVer, const char *sSrc, double fBeg, double fEnd) |
Start a progress bar on the recieving client. More... | |
void | das_send_progup (int nDasVer, const char *sSrc, double fCurrent) |
Update a progress bar on the receiving client. More... | |
The das core library libdas2.a supplies a full API for generating Das2 streams, however these streams are relativily simple and don't really require a heavy weight library for applications that only write a fixed das2 stream type. Most readers fall into this use case.
These functions supply a few fixed functions to assist Das2 readers.
void das_send_stub | ( | int | nDasVer | ) |
Send a stub stream header.
All das2 streams must start with a stream header. This function sends a minimal stream header which is just good enough to be the prefix for an error message. Only call this if your program needs to output an error message before it's sent it's own stream header.
int das_send_nodata | ( | int | nDasVer, |
const char * | sFmt, | ||
... | |||
) |
Output a no data in interval message.
int das_send_queryerr | ( | int | nDasVer, |
const char * | sFmt, | ||
... | |||
) |
Output a "user-messed up" message when receiving a badly formed query.
int das_send_srverr | ( | int | nDasVer, |
const char * | sFmt, | ||
... | |||
) |
Output a server problem message (i.e.
missing spice kernel, etc)
void das_send_msg | ( | int | nDasVer, |
const char * | source, | ||
const char * | sFmt, | ||
... | |||
) |
Output a log status message (i.e.
reading file T120101.DAT)
void das_send_progbeg | ( | int | nDasVer, |
const char * | sSrc, | ||
double | fBeg, | ||
double | fEnd | ||
) |
Start a progress bar on the recieving client.
This function keeps track of the last progress update and will not issue a new one unless at least 1% more progress has been made
nDasVer | the das stream version number you're writing, either 1 or 2 |
sSrc | The name of the thing setting the progress bar |
fBeg | some begin mark, can be any floating point number. |
fEnd | some end mark, can be any floating point number bigger than fBeg |
void das_send_progup | ( | int | nDasVer, |
const char * | sSrc, | ||
double | fCurrent | ||
) |
Update a progress bar on the receiving client.
nDasVer | the das stream version number you're writing, either 1 or 2 |
sSrc | The name of the thing setting the progress bar |
fCurrent | some floating point number between the start and end marks set in das_send_progbeg(). |