RSP_parseNext

Name

RSP_parseNext -- Returns the next set of parsed history data.

Synopsis

RSP_parseLine* RSP_parseNext(RSP_parseData *pd);

Description

This function, called after the RSP_parseBegin routine, is designed to work with an existing connection to a history repository and gather all of the necessary data from the remote entity based on the criteria set in the RSP_parseBegin function. It is important that this function be called soon after calling RSP_parseBegin so that a remote server doesn't time out any network connections that may have been opened.

Each time this function is called a new "line" is returned. If no more data exists, or if there is an error, NULL is returned instead. Each line of data contains a time and a piece of data as well as a graph type if graph data is being returned. The data structure RSP_parseLine is defined as follows:

typedef struct _RSP_parseLine
{
	time_t time;
	char* szData;
	int iGraphType;
} RSP_parseLine;
				

The time is measured in UNIX time, that is, seconds since the Epoch (00:00:00, January 1, 1970).

Returns

The next RSP_parseLine structure retrieved from the server or NULL if all data has been retrieved or an error occurred.

Error Conditions

If an error occurs while retrieving or parsing data, then NULL is returned and the rsp_error variable is set to one of the following error codes: