pazpar2  1.13.0
Enumerations | Functions
client.h File Reference

Z39.50 client. More...

#include "facet_limit.h"
#include "reclists.h"

Go to the source code of this file.


enum  client_state {
  Client_Connecting, Client_Idle, Client_Working, Client_Error,
  Client_Failed, Client_Disconnected


int clients_get_count (void)
int client_show_raw_begin (struct client *cl, int position, const char *syntax, const char *esn, void *data, void(*error_handler)(void *data, const char *addinfo), void(*record_handler)(void *data, const char *buf, size_t sz), int binary, const char *nativesyntax)
void client_show_raw_remove (struct client *cl, void *rr)
const char * client_get_state_str (struct client *cl)
enum client_state client_get_state (struct client *cl)
void client_set_state (struct client *cl, enum client_state st)
void client_set_state_nb (struct client *cl, enum client_state st)
struct connectionclient_get_connection (struct client *cl)
struct session_databaseclient_get_database (struct client *cl)
void client_set_database (struct client *cl, struct session_database *db)
struct sessionclient_get_session (struct client *cl)
void client_search_response (struct client *cl)
void client_record_response (struct client *cl, int *got_records)
struct clientclient_create (const char *url)
int client_destroy (struct client *c)
void client_set_connection (struct client *cl, struct connection *con)
void client_disconnect (struct client *cl)
void client_mark_dead (struct client *cl)
int client_prep_connection (struct client *cl, int operation_timeout, int session_timeout, iochan_man_t iochan, const struct timeval *abstime)
int client_start_search (struct client *cl)
int client_fetch_more (struct client *cl)
int client_parse_init (struct client *cl, int same_search)
int client_parse_range (struct client *cl, const char *startrecs, const char *maxrecs)
int client_parse_sort (struct client *cl, struct reclist_sortparms *sp, int *has_sortmap)
void client_set_session (struct client *cl, struct session *se)
int client_is_active (struct client *cl)
int client_is_active_preferred (struct client *cl)
struct clientclient_next_in_session (struct client *cl)
int client_parse_query (struct client *cl, const char *query, facet_limits_t facet_limits, const char **error_msg)
Odr_int client_get_hits (struct client *cl)
Odr_int client_get_approximation (struct client *cl)
int client_get_num_records (struct client *cl, int *filtered, int *ingest, int *failed)
int client_get_diagnostic (struct client *cl, const char **message, const char **addinfo)
void client_set_diagnostic (struct client *cl, int diagnostic, const char *message, const char *addinfo)
const char * client_get_id (struct client *cl)
int client_get_maxrecs (struct client *cl)
void client_remove_from_session (struct client *c)
void client_incref (struct client *c)
void client_got_records (struct client *c)
void client_lock (struct client *c)
void client_unlock (struct client *c)
void client_stop (struct client *c)
int client_has_facet (struct client *cl, const char *name)
int client_reingest (struct client *cl)
const char * client_get_facet_limit_local (struct client *cl, struct session_database *sdb, int *l, NMEM nmem, int *num, char ***values)
const char * client_get_suggestions_xml (struct client *cl, WRBUF wrbuf)
void client_update_show_stat (struct client *cl, int cmd)
void client_store_xdoc (struct client *cl, int record_no, xmlDoc *xdoc)
const char * client_get_query (struct client *cl, const char **type, NMEM nmem)

Detailed Description

Z39.50 client.

Definition in file client.h.

Enumeration Type Documentation


Definition at line 33 of file client.h.

Function Documentation

struct client* client_create ( const char *  url)
int client_destroy ( struct client c)
void client_disconnect ( struct client cl)
int client_fetch_more ( struct client cl)
Odr_int client_get_approximation ( struct client cl)

Definition at line 1751 of file client.c.

References client_get_id(), client::filtered, client::hits, and client::record_offset.

Referenced by hitsbytarget_nb(), and show_range_start().

struct connection* client_get_connection ( struct client cl)
struct session_database* client_get_database ( struct client cl)
int client_get_diagnostic ( struct client cl,
const char **  message,
const char **  addinfo 

Definition at line 1789 of file client.c.

References client::addinfo, client::diagnostic, and client::message.

Referenced by hitsbytarget_nb().

const char* client_get_facet_limit_local ( struct client cl,
struct session_database sdb,
int *  l,
NMEM  nmem,
int *  num,
char ***  values 
Odr_int client_get_hits ( struct client cl)
const char* client_get_id ( struct client cl)
int client_get_maxrecs ( struct client cl)

Definition at line 1838 of file client.c.

References client::maxrecs.

Referenced by ingest_to_cluster().

int client_get_num_records ( struct client cl,
int *  filtered,
int *  ingest,
int *  failed 
const char* client_get_query ( struct client cl,
const char **  type,
NMEM  nmem 

Definition at line 894 of file client.c.

References client::cqlquery, and client::pquery.

Referenced by hitsbytarget_nb().

struct session* client_get_session ( struct client cl)
enum client_state client_get_state ( struct client cl)

Definition at line 166 of file client.c.

References client::state.

Referenced by session_fetch_more(), session_sort(), and statistics().

const char* client_get_state_str ( struct client cl)

Definition at line 161 of file client.c.

References client_states, and client::state.

Referenced by hitsbytarget_nb(), and session_fetch_more().

const char* client_get_suggestions_xml ( struct client cl,
WRBUF  wrbuf 

Definition at line 1799 of file client.c.

References suggestions::num, suggestions::passthrough, and client::suggestions.

Referenced by hitsbytarget_nb().

void client_got_records ( struct client c)
int client_has_facet ( struct client cl,
const char *  name 
void client_incref ( struct client c)

Definition at line 1101 of file client.c.

References client_get_id(), client::mutex, pazpar2_incref(), and client::ref_count.

Referenced by client_set_connection().

int client_is_active ( struct client cl)
int client_is_active_preferred ( struct client cl)
void client_lock ( struct client c)
void client_mark_dead ( struct client cl)

Definition at line 1170 of file client.c.

References client::connection, and connection_mark_dead().

Referenced by session_remove_cached_clients().

struct client* client_next_in_session ( struct client cl)
int client_parse_init ( struct client cl,
int  same_search 

Definition at line 867 of file client.c.

References client::same_search.

Referenced by session_search(), and session_sort().

int client_parse_query ( struct client cl,
const char *  query,
facet_limits_t  facet_limits,
const char **  error_msg 
int client_parse_range ( struct client cl,
const char *  startrecs,
const char *  maxrecs 

Definition at line 876 of file client.c.

References client::maxrecs, client::same_search, and client::startrecs.

Referenced by session_search().

int client_parse_sort ( struct client cl,
struct reclist_sortparms sp,
int *  has_sortmap 
int client_prep_connection ( struct client cl,
int  operation_timeout,
int  session_timeout,
iochan_man_t  iochan,
const struct timeval *  abstime 
void client_record_response ( struct client cl,
int *  got_records 
int client_reingest ( struct client cl)
void client_remove_from_session ( struct client c)
void client_search_response ( struct client cl)
void client_set_connection ( struct client cl,
struct connection con 
void client_set_database ( struct client cl,
struct session_database db 

Definition at line 1828 of file client.c.

References client::database.

Referenced by select_targets_callback(), and session_remove_cached_clients().

void client_set_diagnostic ( struct client cl,
int  diagnostic,
const char *  message,
const char *  addinfo 

Definition at line 1777 of file client.c.

References client::addinfo, client::diagnostic, and client::message.

Referenced by connection_connect(), non_block_events(), and prepare_cclmap().

void client_set_session ( struct client cl,
struct session se 
void client_set_state ( struct client cl,
enum client_state  st 
void client_set_state_nb ( struct client cl,
enum client_state  st 

Definition at line 171 of file client.c.

References client::state.

Referenced by connection_connect(), and prepare_cclmap().

int client_show_raw_begin ( struct client cl,
int  position,
const char *  syntax,
const char *  esn,
void *  data,
void(*)(void *data, const char *addinfo)  error_handler,
void(*)(void *data, const char *buf, size_t sz)  record_handler,
int  binary,
const char *  nativesyntax 
void client_show_raw_remove ( struct client cl,
void *  rr 

Definition at line 381 of file client.c.

References client_show_raw_delete(), show_raw::data, show_raw::next, and client::show_raw.

int client_start_search ( struct client cl)
void client_stop ( struct client c)
void client_store_xdoc ( struct client cl,
int  record_no,
xmlDoc *  xdoc 

Definition at line 228 of file client.c.

References client::addinfo, client_show_raw_error(), client::xdoc, and XDOC_CACHE_SIZE.

Referenced by ingest_record().

void client_unlock ( struct client c)
void client_update_show_stat ( struct client cl,
int  cmd 

Definition at line 814 of file client.c.

References client::show_stat_no.

Referenced by show_range_start().

int clients_get_count ( void  )

Definition at line 93 of file client.c.

References client_use().

Referenced by cmd_info().