/* Define a simple query by specifying the data record pointed to. */
int jsoc_link_set_static(JSOC_Env_t *env, JSOC_DataRecord_t *dr, const char *link_name,
const char *target_series, int id, int version);
/* Define a query-link by specifying the target series and query. */
int jsoc_link_set_query(JSOC_Env_t *env, JSOC_DataRecord_t *dr, const char *link_name,
const char *target_series, query);
/* Bind a query-link to a specific datarecord by evaluating the link query
on the target series table. Notice that this function is just a no-op
when applied to a static link. */
int jsoc_link_resolve(JSOC_Env_t *env, JSOC_Link_t *link);
/* Return list of all datarecordr linked to *dr. */
JSOC_DataRecord_t *jsoc_dr_get_all_links(JSOC_DataRecord_t *dr);