libdsdb3  3.0
 All Data Structures Files Functions Variables Typedefs Enumerations Macros Groups
Retriever Functions

Data Structures

struct  RetDataStream
 Retriever Datastream. More...
struct  RetDsVarMap
 Retriever Coordinate System Dimension Variable Names Map. More...
struct  RetCoordDim
 Retriever Coordinate System Dimension. More...
struct  RetCoordSystem
 Retriever Coordinate System. More...
struct  RetVarOutput
 Retriever Variable Output Target. More...
struct  RetVariable
 Retriever Variable. More...
struct  RetDsSubGroup
 Retriever Datastream Subgroup. More...
struct  RetDsGroup
 Retriever Datastream Group. More...
struct  Retriever
 Retriever. More...

Functions

void dsdb_free_retriever (Retriever *ret)
 Free all memory used by a Retriever structure.
int dsdb_get_retriever (DSDB *dsdb, const char *proc_type, const char *proc_name, Retriever **retriever)
 Get the Retriever information from the database.
void dsdb_print_retriever (FILE *fp, Retriever *ret)
 Print Retriever structure.
int dsdb_set_retriever_location (Retriever *ret, const char *site, const char *facility)
 Set the location for a Retriever structure.

Detailed Description


Function Documentation

void dsdb_free_retriever ( Retriever ret)

Free all memory used by a Retriever structure.

Parameters:
ret- pointer to the Retriever structure

Definition at line 2259 of file retriever.c.

int dsdb_get_retriever ( DSDB dsdb,
const char *  proc_type,
const char *  proc_name,
Retriever **  retriever 
)

Get the Retriever information from the database.

This function gets the retriever information from the database for the specified process and populates the retriever data structures.

The memory used by the output structure is dynamically allocated. It is the responsibility of the calling process to free this memory when it is no longer needed (see dsdb_free_retriever()).

Error messages from this function are sent to the message handler (see msngr_init_log() and msngr_init_mail()).

Parameters:
dsdb- pointer to the open database connection
proc_type- type of process, usually VAP
proc_name- name of VAP
retriever- output: pointer to the Retriever structure
Returns:
  • 1 if successful
  • 0 if no retriever information was found in the database
  • -1 if an error occurred
See also:
dsdb_free_retriever()

Definition at line 2376 of file retriever.c.

void dsdb_print_retriever ( FILE *  fp,
Retriever ret 
)

Print Retriever structure.

Parameters:
fp- pointer to the output stream to print to
ret- pointer to the Retriever structure

Definition at line 2461 of file retriever.c.

int dsdb_set_retriever_location ( Retriever ret,
const char *  site,
const char *  facility 
)

Set the location for a Retriever structure.

This function will set the site and facility values in all datastream structures, and filter out the datastreams that have site and/or facility depedencies that do not match the specified site and/or facility.

Error messages from this function are sent to the message handler (see msngr_init_log() and msngr_init_mail()).

Parameters:
ret- pointer to the Retriever structure
site- site name
facility- facility name
Returns:
  • 1 if successful
  • 0 if one of the following errors occurred:
    • site and/or facility argument(s) were NULL
    • all input datastreams for a required variable were filtered
    • all input datastreams for a coordinate variable map were filtered
    • memory allocation error

Definition at line 2788 of file retriever.c.