YAZ
5.34.0
|
Header for ZOOM. More...
Go to the source code of this file.
Typedefs | |
typedef typedefZOOM_BEGIN_CDECL struct ZOOM_options_p * | ZOOM_options |
typedef struct ZOOM_query_p * | ZOOM_query |
typedef struct ZOOM_connection_p * | ZOOM_connection |
typedef struct ZOOM_resultset_p * | ZOOM_resultset |
typedef struct ZOOM_record_p * | ZOOM_record |
typedef struct ZOOM_facet_field_p * | ZOOM_facet_field |
typedef struct ZOOM_scanset_p * | ZOOM_scanset |
typedef struct ZOOM_package_p * | ZOOM_package |
typedef const char *(* | ZOOM_options_callback) (void *handle, const char *name) |
Header for ZOOM.
Definition in file zoom.h.
#define ZOOM_BEGIN_CDECL YAZ_BEGIN_CDECL |
#define ZOOM_END_CDECL YAZ_END_CDECL |
typedef struct ZOOM_connection_p* ZOOM_connection |
typedef struct ZOOM_facet_field_p* ZOOM_facet_field |
typedef typedefZOOM_BEGIN_CDECL struct ZOOM_options_p* ZOOM_options |
typedef const char*(* ZOOM_options_callback) (void *handle, const char *name) |
typedef struct ZOOM_package_p* ZOOM_package |
typedef struct ZOOM_query_p* ZOOM_query |
typedef struct ZOOM_record_p* ZOOM_record |
typedef struct ZOOM_resultset_p* ZOOM_resultset |
typedef struct ZOOM_scanset_p* ZOOM_scanset |
ZOOM_connection_addinfo | ( | ZOOM_connection | c | ) |
Definition at line 1860 of file zoom-c.c.
References ZOOM_connection_error().
ZOOM_connection_close | ( | ZOOM_connection | c | ) |
Referenced by do_connect_host(), do_read(), do_write_ex(), handle_http(), ZOOM_connection_do_io(), ZOOM_handle_Z3950_apdu(), and ZOOM_test_reconnect().
ZOOM_connection_connect | ( | ZOOM_connection | c, |
const char * | host, | ||
int | portnum | ||
) |
Definition at line 361 of file zoom-c.c.
References get_sru_mode_from_string(), initlog(), odr_createmem(), odr_destroy(), ODR_PRINT, odr_setprint(), odr_setprint_noclose(), wrbuf_alloc(), wrbuf_cstr(), wrbuf_destroy(), wrbuf_printf(), xfree, xmalloc, xstrdup, yaz_cookies_create(), yaz_cookies_destroy(), yaz_log(), yaz_log_file(), ZOOM_connection_add_task(), ZOOM_connection_option_set(), ZOOM_connection_remove_tasks(), ZOOM_ERROR_INTERNAL, ZOOM_ERROR_NONE, ZOOM_ERROR_UNSUPPORTED_PROTOCOL, ZOOM_event(), ZOOM_memcached_configure(), ZOOM_options_get(), ZOOM_options_get_bool(), ZOOM_options_get_int(), ZOOM_options_set(), ZOOM_set_error(), zoom_sru_error, and ZOOM_TASK_CONNECT.
Referenced by ZOOM_connection_new().
ZOOM_connection_create | ( | ZOOM_options | options | ) |
Definition at line 237 of file zoom-c.c.
References ZOOM_connection_p::addinfo, ZOOM_connection_p::async, ZOOM_connection_p::buf_in, ZOOM_connection_p::buf_out, ZOOM_connection_p::charset, ZOOM_connection_p::client_IP, ZOOM_connection_p::cookie_in, ZOOM_connection_p::cookie_out, ZOOM_connection_p::cookies, ZOOM_connection_p::cs, ZOOM_connection_p::diagset, ZOOM_connection_p::group, ZOOM_connection_p::host_port, initlog(), ZOOM_connection_p::lang, ZOOM_connection_p::last_event, ZOOM_connection_p::len_in, ZOOM_connection_p::len_out, ZOOM_connection_p::location, ZOOM_connection_p::log_api, log_api0, ZOOM_connection_p::log_details, log_details0, ZOOM_connection_p::m_queue_back, ZOOM_connection_p::m_queue_front, ZOOM_connection_p::maximum_record_size, ZOOM_connection_p::no_redirects, odr_createmem(), ODR_DECODE, ODR_ENCODE, ZOOM_connection_p::odr_in, ZOOM_connection_p::odr_out, ZOOM_connection_p::odr_print, ZOOM_connection_p::odr_save, options(), ZOOM_connection_p::options, ZOOM_connection_p::password, ZOOM_connection_p::preferred_message_size, ZOOM_connection_p::proto, PROTO_Z3950, ZOOM_connection_p::proxy, ZOOM_connection_p::proxy_mode, ZOOM_connection_p::reconnect_ok, ZOOM_connection_p::resultsets, ZOOM_connection_p::saveAPDU_wrbuf, ZOOM_connection_p::sru_version, ZOOM_connection_p::state, STATE_IDLE, ZOOM_connection_p::support_named_resultsets, ZOOM_connection_p::tasks, ZOOM_connection_p::tproxy, ZOOM_connection_p::url_authentication, ZOOM_connection_p::user, xmalloc, yaz_log(), ZOOM_connection_set_mask(), ZOOM_ERROR_NONE, ZOOM_EVENT_NONE, ZOOM_memcached_init(), ZOOM_options_create_with_parent(), and ZOOM_set_error().
Referenced by ZOOM_connection_new(), and ZOOM_query_cql2rpn().
ZOOM_connection_destroy | ( | ZOOM_connection | c | ) |
Definition at line 605 of file zoom-c.c.
References ZOOM_resultset_p::connection, cs_close, ZOOM_resultset_p::next, odr_destroy(), wrbuf_destroy(), xfree, yaz_cookies_destroy(), yaz_log(), ZOOM_connection_remove_events(), ZOOM_connection_remove_tasks(), ZOOM_memcached_destroy(), and ZOOM_options_destroy().
Referenced by ZOOM_query_cql2rpn().
ZOOM_connection_diagset | ( | ZOOM_connection | c | ) |
Definition at line 1868 of file zoom-c.c.
References ZOOM_connection_error_x().
ZOOM_connection_errcode | ( | ZOOM_connection | c | ) |
Definition at line 1846 of file zoom-c.c.
References ZOOM_connection_error().
ZOOM_connection_errmsg | ( | ZOOM_connection | c | ) |
Definition at line 1852 of file zoom-c.c.
References ZOOM_connection_error().
ZOOM_connection_error | ( | ZOOM_connection | c, |
const char ** | cp, | ||
const char ** | addinfo | ||
) |
Definition at line 1951 of file zoom-c.c.
References ZOOM_connection_error_x().
Referenced by ZOOM_connection_addinfo(), ZOOM_connection_errcode(), and ZOOM_connection_errmsg().
ZOOM_connection_error_x | ( | ZOOM_connection | c, |
const char ** | cp, | ||
const char ** | addinfo, | ||
const char ** | diagset | ||
) |
Definition at line 1926 of file zoom-c.c.
References yaz_diag_srw_str(), z_HTTP_errmsg(), and ZOOM_diag_str().
Referenced by ZOOM_connection_diagset(), and ZOOM_connection_error().
ZOOM_connection_exec_task | ( | ZOOM_connection | c | ) |
executes non-blocking tasks for connection
c | connection |
0 | no task was executed |
1 | task was executed (but probably not completed) |
This function, unlike, ZOOM_connection_process, does not try to return any events (and remove them). But events may be generated from it. These are saved and may later be retrieved with ZOOM_connection_process and ZOOM_connection_last_event .
Definition at line 1435 of file zoom-c.c.
References do_connect(), PROTO_HTTP, ZOOM_task_p::running, send_package(), send_Z3950_sort(), ZOOM_task_p::which, yaz_log(), zoom_complete, ZOOM_connection_remove_task(), ZOOM_connection_remove_tasks(), ZOOM_connection_srw_send_scan(), ZOOM_connection_srw_send_search(), ZOOM_connection_Z3950_search(), ZOOM_connection_Z3950_send_scan(), ZOOM_ERROR_NONE, ZOOM_query_get_sortspec(), ZOOM_TASK_CONNECT, ZOOM_TASK_PACKAGE, ZOOM_TASK_SCAN, ZOOM_TASK_SEARCH, and ZOOM_TASK_SORT.
Referenced by do_connect_host(), ZOOM_connection_do_io(), ZOOM_connection_process(), and ZOOM_handle_Z3950_apdu().
ZOOM_connection_fire_event_socket | ( | ZOOM_connection | c, |
int | mask | ||
) |
fire socket event activity (read,write,except)
c | connection |
mask | or'ed mask of ZOOM_SELECT_.. values |
0 | event was fired OK |
-1 | event was not fired |
Referenced by ZOOM_event_sys_yaz_poll().
ZOOM_connection_fire_event_timeout | ( | ZOOM_connection | c | ) |
fire socket event timeout
c | connection |
0 | event was fired OK |
-1 | event was not fired |
Call this function when a timeout occurs - for example in the case of select(2) returning 0.
Referenced by ZOOM_event_sys_yaz_poll().
ZOOM_connection_get_mask | ( | ZOOM_connection | c | ) |
get socket mask for connection
c | connection |
Use this function when preparing for socket select/poll and in conjunction with ZOOM_connection_get_socket.
Referenced by ZOOM_event_sys_yaz_poll().
ZOOM_connection_get_socket | ( | ZOOM_connection | c | ) |
get socket fd for ZOOM connection
c | connection |
-1 | no socket assigned for connection |
>=0 | socket for connection |
Use this function when preparing for socket/poll and in conjunction with ZOOM_connection_get_mask.
Referenced by ZOOM_event_sys_yaz_poll().
ZOOM_connection_get_timeout | ( | ZOOM_connection | c | ) |
get timeout in seconds for ZOOM connection
c | connection |
Use this function when preparing for socket/poll and in conjunction with ZOOM_connection_get_socket.
Referenced by ZOOM_event_sys_yaz_poll().
ZOOM_connection_is_idle | ( | ZOOM_connection | c | ) |
determines if connection is idle (no active or pending work)
c | connection |
1 | is idle |
0 | is non-idle (active) |
ZOOM_connection_last_event | ( | ZOOM_connection | cs | ) |
Definition at line 2035 of file zoom-c.c.
References ZOOM_EVENT_NONE.
ZOOM_connection_new | ( | const char * | host, |
int | portnum | ||
) |
Definition at line 337 of file zoom-c.c.
References ZOOM_connection_connect(), and ZOOM_connection_create().
ZOOM_connection_option_get | ( | ZOOM_connection | c, |
const char * | key | ||
) |
Definition at line 1770 of file zoom-c.c.
References wrbuf_cstr(), and ZOOM_options_get().
Referenced by cql2pqf().
ZOOM_connection_option_getl | ( | ZOOM_connection | c, |
const char * | key, | ||
int * | lenp | ||
) |
Definition at line 1781 of file zoom-c.c.
References wrbuf_cstr(), wrbuf_len, and ZOOM_options_getl().
ZOOM_connection_option_set | ( | ZOOM_connection | c, |
const char * | key, | ||
const char * | val | ||
) |
Definition at line 1801 of file zoom-c.c.
References wrbuf_alloc(), wrbuf_destroy(), wrbuf_rewind(), and ZOOM_options_set().
Referenced by set_init_option(), ZOOM_connection_connect(), and ZOOM_handle_Z3950_apdu().
ZOOM_connection_option_setl | ( | ZOOM_connection | c, |
const char * | key, | ||
const char * | val, | ||
int | len | ||
) |
ZOOM_connection_package | ( | ZOOM_connection | c, |
ZOOM_options | options | ||
) |
Definition at line 1379 of file zoom-c.c.
References ZOOM_package_p::buf_out, ZOOM_package_p::connection, ZOOM_package_p::len_out, odr_createmem(), ODR_ENCODE, ZOOM_package_p::odr_out, options(), ZOOM_package_p::options, ZOOM_package_p::refcount, xmalloc, and ZOOM_options_create_with_parent2().
ZOOM_connection_peek_event | ( | ZOOM_connection | c | ) |
peek at next event
c | connection |
Does not actually remove the event from the event queue. ZOOM_event and ZOOM_process_event removes one event.
ZOOM_connection_process | ( | ZOOM_connection | c | ) |
process one event for connection
c | connection |
0 | no event was processed |
1 | event was processed for connection |
This function attemps to deal with outstandings events in a non-blocking fashion. If no event was processed (return value of 0), then the system should attempt to deal with sockets in blocking mode using socket select/poll which means calling the following functions: ZOOM_connection_get_socket, ZOOM_connection_get_mask, ZOOM_connection_get_timeout. If an event was processed call this function again.
Definition at line 2057 of file zoom-c.c.
References ZOOM_connection_exec_task(), ZOOM_connection_get_event(), and ZOOM_Event_destroy().
Referenced by ZOOM_event_nonblock().
ZOOM_connection_scan | ( | ZOOM_connection | c, |
const char * | startterm | ||
) |
Definition at line 1177 of file zoom-c.c.
References ZOOM_connection_scan1(), ZOOM_query_create(), ZOOM_query_destroy(), and ZOOM_query_prefix().
ZOOM_connection_scan1 | ( | ZOOM_connection | c, |
ZOOM_query | startterm | ||
) |
Definition at line 1191 of file zoom-c.c.
References ZOOM_scanset_p::connection, ZOOM_scanset_p::databaseNames, ZOOM_scanset_p::num_databaseNames, ZOOM_scanset_p::odr, odr_createmem(), ODR_DECODE, ZOOM_scanset_p::options, ZOOM_scanset_p::query, ZOOM_scanset_p::refcount, ZOOM_task_p::scan, ZOOM_scanset_p::scan_response, ZOOM_scanset_p::srw_scan_response, ZOOM_task_p::u, xmalloc, ZOOM_connection_add_task(), ZOOM_connection_get_databases(), ZOOM_event(), ZOOM_options_create_with_parent(), ZOOM_query_addref(), ZOOM_query_get_Z_Query(), and ZOOM_TASK_SCAN.
Referenced by ZOOM_connection_scan().
ZOOM_connection_search | ( | ZOOM_connection | c, |
ZOOM_query | q | ||
) |
Definition at line 735 of file zoom-c.c.
References ZOOM_resultset_p::connection, ZOOM_resultset_p::databaseNames, ZOOM_resultset_p::next, ZOOM_resultset_p::num_databaseNames, ZOOM_resultset_p::odr, odr_strdup_null(), ZOOM_resultset_p::options, ZOOM_resultset_p::piggyback, PROTO_HTTP, ZOOM_resultset_p::query, ZOOM_resultset_p::r_sort_spec, ZOOM_resultset_p::req_facets, ZOOM_task_p::search, ZOOM_resultset_p::setname, ZOOM_resultset_p::step, ZOOM_task_p::u, xstrdup, yaz_log(), ZOOM_connection_add_task(), ZOOM_connection_get_databases(), ZOOM_event(), ZOOM_memcached_resultset(), ZOOM_options_create_with_parent(), ZOOM_options_get(), ZOOM_options_get_bool(), ZOOM_options_get_int(), ZOOM_query_addref(), ZOOM_query_get_sortspec(), ZOOM_resultset_addref(), ZOOM_resultset_create(), ZOOM_TASK_CONNECT, and ZOOM_TASK_SEARCH.
Referenced by ZOOM_connection_search_pqf().
ZOOM_connection_search_pqf | ( | ZOOM_connection | c, |
const char * | q | ||
) |
Definition at line 722 of file zoom-c.c.
References ZOOM_connection_search(), ZOOM_query_create(), ZOOM_query_destroy(), and ZOOM_query_prefix().
ZOOM_connection_set_mask | ( | ZOOM_connection | c, |
int | mask | ||
) |
set socket mask for connection (DO NOT call outside zoom)
Referenced by do_connect_host(), do_write_ex(), handle_http(), ZOOM_connection_create(), ZOOM_connection_do_io(), and ZOOM_handle_Z3950_apdu().
ZOOM_diag_str | ( | int | error | ) |
Definition at line 1876 of file zoom-c.c.
References diagbib1_str(), ZOOM_ERROR_CCL_CONFIG, ZOOM_ERROR_CCL_PARSE, ZOOM_ERROR_CONNECT, ZOOM_ERROR_CONNECTION_LOST, ZOOM_ERROR_CQL_PARSE, ZOOM_ERROR_CQL_TRANSFORM, ZOOM_ERROR_DECODE, ZOOM_ERROR_ENCODE, ZOOM_ERROR_ES_INVALID_ACTION, ZOOM_ERROR_ES_INVALID_SYNTAX, ZOOM_ERROR_ES_INVALID_VERSION, ZOOM_ERROR_INIT, ZOOM_ERROR_INTERNAL, ZOOM_ERROR_INVALID_QUERY, ZOOM_ERROR_MEMCACHED, ZOOM_ERROR_MEMORY, ZOOM_ERROR_NONE, ZOOM_ERROR_TIMEOUT, ZOOM_ERROR_UNSUPPORTED_PROTOCOL, and ZOOM_ERROR_UNSUPPORTED_QUERY.
Referenced by ZOOM_connection_error_x().
ZOOM_event | ( | int | no, |
ZOOM_connection * | cs | ||
) |
wait for events on connection(s) (BLOCKING)
no | number of connections (size of cs) |
cs | connection array |
0 | no event was fired |
>0 | event was fired for connection at (retval-1) |
blocking poll for events on a number of connections. Returns positive integer if event occurred ; zero if none occurred and no more events are pending. The positive integer specifies the connection for which the event occurred.
Definition at line 99 of file zoom-socket.c.
References ZOOM_event_nonblock(), and ZOOM_event_sys_yaz_poll().
Referenced by ZOOM_connection_connect(), ZOOM_connection_scan1(), ZOOM_connection_search(), ZOOM_package_send(), ZOOM_resultset_retrieve(), and ZOOM_resultset_sort1().
ZOOM_event_nonblock | ( | int | no, |
ZOOM_connection * | cs | ||
) |
process one event for one of connections given
no | number of connections (size of cs) |
cs | connection array |
0 | no event was processed |
>0 | event was processed for connection at (retval-1) |
This function attemps to deal with outstandings events in a non-blocking mode. If no events was processed (return value of 0), then the system should attempt to deal with sockets in blocking mode using socket select/poll which means calling the following functions: ZOOM_connection_get_socket, ZOOM_connection_get_mask, ZOOM_connection_get_timeout.
Definition at line 2080 of file zoom-c.c.
References log_details0, yaz_log(), and ZOOM_connection_process().
Referenced by ZOOM_event().
ZOOM_facet_field_get_term | ( | ZOOM_facet_field | facet_field, |
size_t | idx, | ||
int * | freq | ||
) |
ZOOM_facet_field_name | ( | ZOOM_facet_field | facet_field | ) |
Definition at line 1034 of file zoom-c.c.
Referenced by ZOOM_handle_facet_list().
ZOOM_facet_field_term_count | ( | ZOOM_facet_field | facet_field | ) |
ZOOM_get_event_str | ( | int | event | ) |
ZOOM_options_create | ( | void | ) |
Definition at line 87 of file zoom-opt.c.
References ZOOM_options_create_with_parent().
Referenced by ZOOM_options_dup().
ZOOM_options_create_with_parent | ( | ZOOM_options | parent | ) |
Definition at line 81 of file zoom-opt.c.
References ZOOM_options_create_with_parent2().
Referenced by ZOOM_connection_create(), ZOOM_connection_scan1(), ZOOM_connection_search(), and ZOOM_options_create().
ZOOM_options_create_with_parent2 | ( | ZOOM_options | parent1, |
ZOOM_options | parent2 | ||
) |
Definition at line 94 of file zoom-opt.c.
Referenced by ZOOM_connection_package(), and ZOOM_options_create_with_parent().
ZOOM_options_destroy | ( | ZOOM_options | opt | ) |
Definition at line 134 of file zoom-opt.c.
References ZOOM_options_entry::name, ZOOM_options_entry::next, opt, ZOOM_options_entry::value, xfree, and ZOOM_options_destroy().
Referenced by resultset_destroy(), ZOOM_connection_destroy(), ZOOM_options_destroy(), ZOOM_package_destroy(), and ZOOM_scanset_destroy().
ZOOM_options_dup | ( | ZOOM_options | src | ) |
Definition at line 58 of file zoom-opt.c.
References append_entry(), ZOOM_options_entry::len, ZOOM_options_entry::name, ZOOM_options_entry::next, ZOOM_options_entry::value, ZOOM_options_create(), and ZOOM_options_dup().
Referenced by ZOOM_options_dup().
ZOOM_options_get | ( | ZOOM_options | opt, |
const char * | name | ||
) |
Definition at line 216 of file zoom-opt.c.
References name, opt, and ZOOM_options_getl().
Referenced by create_es_package(), create_update_package(), encode_item_order(), ill_array_lookup(), otherInfo_attach(), send_srw(), Z3950_send_search(), ZOOM_connection_connect(), ZOOM_connection_get_databases(), ZOOM_connection_option_get(), ZOOM_connection_search(), ZOOM_connection_srw_send_scan(), ZOOM_connection_Z3950_send_init(), ZOOM_connection_Z3950_send_scan(), ZOOM_memcached_configure(), ZOOM_options_get_bool(), ZOOM_options_get_int(), ZOOM_package_option_get(), ZOOM_resultset_option_get(), ZOOM_resultset_record_immediate(), ZOOM_resultset_retrieve(), and ZOOM_scanset_option_get().
ZOOM_options_get_bool | ( | ZOOM_options | opt, |
const char * | name, | ||
int | defa | ||
) |
Definition at line 223 of file zoom-opt.c.
References name, opt, and ZOOM_options_get().
Referenced by ZOOM_connection_connect(), and ZOOM_connection_search().
ZOOM_options_get_int | ( | ZOOM_options | opt, |
const char * | name, | ||
int | defa | ||
) |
Definition at line 235 of file zoom-opt.c.
References name, opt, and ZOOM_options_get().
Referenced by Z3950_send_search(), ZOOM_connection_connect(), ZOOM_connection_search(), ZOOM_connection_srw_send_scan(), and ZOOM_connection_Z3950_send_scan().
ZOOM_options_getl | ( | ZOOM_options | opt, |
const char * | name, | ||
int * | lenp | ||
) |
Definition at line 186 of file zoom-opt.c.
References ZOOM_options_entry::len, name, ZOOM_options_entry::name, ZOOM_options_entry::next, opt, ZOOM_options_entry::value, and ZOOM_options_getl().
Referenced by create_update_package(), create_xmlupdate_package(), encode_item_order(), ZOOM_connection_option_getl(), ZOOM_options_get(), ZOOM_options_getl(), and ZOOM_package_option_getl().
ZOOM_options_set | ( | ZOOM_options | opt, |
const char * | name, | ||
const char * | v | ||
) |
Definition at line 180 of file zoom-opt.c.
References name, opt, ZOOM_options_entry::value, and ZOOM_options_setl().
Referenced by es_response_taskpackage(), es_response_taskpackage_update(), es_response_taskpackage_update0(), handle_queryExpressionTerm(), handle_Z3950_es_response(), handle_Z3950_search_response(), Z3950_send_search(), ZOOM_connection_connect(), ZOOM_connection_option_set(), ZOOM_connection_srw_send_search(), ZOOM_handle_search_result(), ZOOM_handle_sru(), ZOOM_options_set_int(), ZOOM_package_option_set(), ZOOM_resultset_option_set(), and ZOOM_scanset_option_set().
ZOOM_options_set_callback | ( | ZOOM_options | opt, |
ZOOM_options_callback | c, | ||
void * | handle | ||
) |
Definition at line 119 of file zoom-opt.c.
References opt.
ZOOM_options_set_int | ( | ZOOM_options | opt, |
const char * | name, | ||
int | value | ||
) |
Definition at line 245 of file zoom-opt.c.
References name, opt, ZOOM_options_entry::value, and ZOOM_options_set().
Referenced by handle_queryExpressionTerm(), handle_srw_scan_response(), handle_Z3950_es_response(), handle_Z3950_scan_response(), handle_Z3950_search_response(), and ZOOM_handle_search_result().
ZOOM_options_setl | ( | ZOOM_options | opt, |
const char * | name, | ||
const char * | value, | ||
int | len | ||
) |
Definition at line 160 of file zoom-opt.c.
References append_entry(), ZOOM_options_entry::len, name, ZOOM_options_entry::next, opt, set_value(), ZOOM_options_entry::value, and xfree.
Referenced by es_response_taskpackage(), handle_queryExpressionTerm(), handle_Z3950_es_response(), ZOOM_connection_option_setl(), ZOOM_handle_sru(), ZOOM_options_set(), and ZOOM_package_option_setl().
ZOOM_package_destroy | ( | ZOOM_package | p | ) |
Definition at line 1393 of file zoom-c.c.
References odr_destroy(), xfree, and ZOOM_options_destroy().
Referenced by ZOOM_connection_remove_task().
ZOOM_package_option_get | ( | ZOOM_package | p, |
const char * | key | ||
) |
Definition at line 1409 of file zoom-c.c.
References ZOOM_options_get().
ZOOM_package_option_getl | ( | ZOOM_package | p, |
const char * | key, | ||
int * | lenp | ||
) |
Definition at line 1415 of file zoom-c.c.
References ZOOM_options_getl().
ZOOM_package_option_set | ( | ZOOM_package | p, |
const char * | key, | ||
const char * | val | ||
) |
Definition at line 1421 of file zoom-c.c.
References ZOOM_options_set().
ZOOM_package_option_setl | ( | ZOOM_package | p, |
const char * | key, | ||
const char * | val, | ||
int | len | ||
) |
Definition at line 1428 of file zoom-c.c.
References ZOOM_options_setl().
ZOOM_package_send | ( | ZOOM_package | p, |
const char * | type | ||
) |
Definition at line 891 of file zoom-z3950.c.
References ZOOM_connection_p::async, create_admin_package(), create_es_package(), create_update_package(), create_xmlupdate_package(), Z_External::descriptor, Z_External::direct_reference, encode_APDU(), encode_item_order(), Z_APDU::extendedServicesRequest, Z_External::indirect_reference, Z_External::itemOrder, odr_getbuf(), odr_malloc(), odr_oiddup(), odr_reset(), ZOOM_task_p::package, Z_ExtendedServicesRequest::taskSpecificParameters, type, Z_External::u, Z_APDU::u, ZOOM_task_p::u, Z_External::which, xfree, xmalloc, yaz_oid_extserv_item_order, Z_ESAdminOriginPartToKeep_commit, Z_ESAdminOriginPartToKeep_create, Z_ESAdminOriginPartToKeep_drop, Z_External_itemOrder, ZOOM_connection_add_task(), ZOOM_event(), and ZOOM_TASK_PACKAGE.
ZOOM_query_addref | ( | ZOOM_query | s | ) |
Definition at line 248 of file zoom-query.c.
Referenced by ZOOM_connection_scan1(), and ZOOM_connection_search().
ZOOM_query_ccl2rpn | ( | ZOOM_query | s, |
const char * | query_str, | ||
const char * | config, | ||
int * | ccl_error, | ||
const char ** | error_string, | ||
int * | error_pos | ||
) |
Definition at line 306 of file zoom-query.c.
References ccl_err_msg(), ccl_find_str(), ccl_pquery(), ccl_qual_buf(), ccl_qual_mk(), ccl_qual_rm(), ccl_rpn_delete(), wrbuf_alloc(), wrbuf_cstr(), wrbuf_destroy(), and ZOOM_query_prefix().
ZOOM_query_cql | ( | ZOOM_query | s, |
const char * | str | ||
) |
Definition at line 264 of file zoom-query.c.
References generate(), xfree, xstrdup, and Z_Query_type_104.
ZOOM_query_cql2rpn | ( | ZOOM_query | s, |
const char * | str, | ||
ZOOM_connection | conn | ||
) |
Definition at line 280 of file zoom-query.c.
References cql2pqf(), xfree, ZOOM_connection_create(), ZOOM_connection_destroy(), and ZOOM_query_prefix().
ZOOM_query_create | ( | void | ) |
Definition at line 213 of file zoom-query.c.
References ZOOM_query_p::full_query, odr_createmem(), ODR_ENCODE, ZOOM_query_p::odr_query, ZOOM_query_p::odr_sort_spec, ZOOM_query_p::query_string, ZOOM_query_p::refcount, ZOOM_query_p::sort_spec, ZOOM_query_p::sort_strategy, SORT_STRATEGY_Z3950, ZOOM_query_p::sru11_sort_spec, wrbuf_alloc(), xmalloc, and ZOOM_query_p::z_query.
Referenced by ZOOM_connection_scan(), ZOOM_connection_search_pqf(), and ZOOM_resultset_sort1().
ZOOM_query_destroy | ( | ZOOM_query | s | ) |
Definition at line 230 of file zoom-query.c.
References odr_destroy(), wrbuf_destroy(), and xfree.
Referenced by resultset_destroy(), ZOOM_connection_remove_task(), ZOOM_connection_scan(), ZOOM_connection_search_pqf(), and ZOOM_scanset_destroy().
ZOOM_query_prefix | ( | ZOOM_query | s, |
const char * | str | ||
) |
Definition at line 255 of file zoom-query.c.
References generate(), xfree, xstrdup, and Z_Query_type_1.
Referenced by ZOOM_connection_scan(), ZOOM_connection_search_pqf(), ZOOM_query_ccl2rpn(), and ZOOM_query_cql2rpn().
ZOOM_query_sortby | ( | ZOOM_query | s, |
const char * | criteria | ||
) |
Definition at line 336 of file zoom-query.c.
References ZOOM_query_sortby2().
Referenced by ZOOM_resultset_sort1().
ZOOM_query_sortby2 | ( | ZOOM_query | s, |
const char * | strategy, | ||
const char * | criteria | ||
) |
Definition at line 342 of file zoom-query.c.
References generate(), odr_reset(), SORT_STRATEGY_CQL, SORT_STRATEGY_EMBED, SORT_STRATEGY_SOLR, SORT_STRATEGY_SRU11, SORT_STRATEGY_TYPE7, SORT_STRATEGY_Z3950, and yaz_sort_spec().
Referenced by ZOOM_query_sortby().
ZOOM_record_clone | ( | ZOOM_record | srec | ) |
Definition at line 179 of file zoom-record-cache.c.
References ZOOM_record_p::diag_details, ZOOM_record_p::diag_message, ZOOM_record_p::diag_set, ZOOM_record_p::diag_uri, ZOOM_record_p::npr, ZOOM_record_p::odr, odr_createmem(), ODR_DECODE, odr_destroy(), ODR_ENCODE, odr_getbuf(), odr_setbuf(), odr_strdup_null(), ZOOM_record_p::record_wrbuf, ZOOM_record_p::schema, xmalloc, and z_NamePlusRecord().
ZOOM_record_destroy | ( | ZOOM_record | rec | ) |
Definition at line 330 of file zoom-record-cache.c.
References xfree, and ZOOM_record_release().
ZOOM_record_error | ( | ZOOM_record | rec, |
const char ** | msg, | ||
const char ** | addinfo, | ||
const char ** | diagset | ||
) |
Definition at line 270 of file zoom-record-cache.c.
References Z_DefaultDiagFormat::condition, Z_DiagRec::defaultFormat, diagbib1_str(), Z_DefaultDiagFormat::diagnosticSetId, ZOOM_record_p::npr, Z_NamePlusRecord::surrogateDiagnostic, Z_NamePlusRecord::u, Z_DiagRec::u, Z_DefaultDiagFormat::u, Z_DefaultDiagFormat::v2Addinfo, Z_DefaultDiagFormat::v3Addinfo, Z_NamePlusRecord::which, Z_DiagRec::which, Z_DefaultDiagFormat::which, YAZ_BIB1_UNSPECIFIED_ERROR, yaz_oid_std(), yaz_oid_to_string(), Z_DefaultDiagFormat_v2Addinfo, Z_DefaultDiagFormat_v3Addinfo, Z_DiagRec_defaultFormat, Z_NamePlusRecord_surrogateDiagnostic, and ZOOM_uri_to_code().
ZOOM_record_get | ( | ZOOM_record | rec, |
const char * | type, | ||
int * | len | ||
) |
Definition at line 244 of file zoom-record-cache.c.
References wrbuf_alloc(), yaz_record_render(), and YAZ_SHPTR_INIT.
ZOOM_resultset_cache_reset | ( | ZOOM_resultset | r | ) |
Definition at line 228 of file zoom-record-cache.c.
References ZOOM_record_cache_p::next, ZOOM_record_cache_p::rec, RECORD_HASH_SIZE, and ZOOM_record_release().
Referenced by resultset_destroy(), and ZOOM_resultset_sort1().
ZOOM_resultset_destroy | ( | ZOOM_resultset | r | ) |
Definition at line 863 of file zoom-c.c.
References resultset_destroy().
ZOOM_resultset_facets | ( | ZOOM_resultset | r | ) |
ZOOM_resultset_facets_names | ( | ZOOM_resultset | r | ) |
ZOOM_resultset_facets_size | ( | ZOOM_resultset | r | ) |
ZOOM_resultset_get_facet_field | ( | ZOOM_resultset | r, |
const char * | facet_name | ||
) |
ZOOM_resultset_get_facet_field_by_index | ( | ZOOM_resultset | r, |
int | pos | ||
) |
ZOOM_resultset_option_get | ( | ZOOM_resultset | r, |
const char * | key | ||
) |
Definition at line 1832 of file zoom-c.c.
References ZOOM_options_get().
Referenced by ZOOM_connection_srw_send_search(), and ZOOM_memcached_resultset().
ZOOM_resultset_option_set | ( | ZOOM_resultset | r, |
const char * | key, | ||
const char * | val | ||
) |
Definition at line 1838 of file zoom-c.c.
References ZOOM_options_set().
Referenced by handle_srw_response().
ZOOM_resultset_record | ( | ZOOM_resultset | s, |
size_t | pos | ||
) |
Definition at line 1156 of file zoom-c.c.
References ZOOM_resultset_record_immediate(), and ZOOM_resultset_retrieve().
ZOOM_resultset_record_immediate | ( | ZOOM_resultset | s, |
size_t | pos | ||
) |
Definition at line 1143 of file zoom-c.c.
References ZOOM_options_get(), and ZOOM_record_cache_lookup_i().
Referenced by ZOOM_resultset_record(), and ZOOM_resultset_records().
ZOOM_resultset_records | ( | ZOOM_resultset | r, |
ZOOM_record * | recs, | ||
size_t | start, | ||
size_t | count | ||
) |
Definition at line 973 of file zoom-c.c.
References log_api0, yaz_log(), ZOOM_resultset_record_immediate(), and ZOOM_resultset_retrieve().
ZOOM_resultset_release | ( | ZOOM_resultset | r | ) |
release result set from connection.
The result will will no longer be able to perform retrievals from the connection from which it was created.
Referenced by resultset_destroy().
ZOOM_resultset_size | ( | ZOOM_resultset | r | ) |
ZOOM_resultset_sort | ( | ZOOM_resultset | r, |
const char * | sort_type, | ||
const char * | sort_spec | ||
) |
Definition at line 808 of file zoom-c.c.
References ZOOM_resultset_sort1().
ZOOM_resultset_sort1 | ( | ZOOM_resultset | r, |
const char * | sort_type, | ||
const char * | sort_spec | ||
) |
Definition at line 815 of file zoom-c.c.
References ZOOM_connection_p::async, ZOOM_connection_p::cs, ZOOM_connection_p::host_port, ZOOM_connection_p::log_api, ZOOM_connection_p::log_details, ZOOM_connection_p::proto, PROTO_HTTP, ZOOM_connection_p::reconnect_ok, ZOOM_task_p::sort, ZOOM_task_p::u, yaz_log(), ZOOM_connection_add_task(), ZOOM_event(), ZOOM_query_create(), ZOOM_query_sortby(), ZOOM_resultset_addref(), ZOOM_resultset_cache_reset(), ZOOM_TASK_CONNECT, and ZOOM_TASK_SORT.
Referenced by ZOOM_resultset_sort().
ZOOM_scanset_destroy | ( | ZOOM_scanset | scan | ) |
Definition at line 1228 of file zoom-c.c.
References odr_destroy(), xfree, ZOOM_options_destroy(), and ZOOM_query_destroy().
Referenced by ZOOM_connection_remove_task().
ZOOM_scanset_display_term | ( | ZOOM_scanset | scan, |
size_t | pos, | ||
size_t * | occ, | ||
size_t * | len | ||
) |
Definition at line 1349 of file zoom-c.c.
References ZOOM_scanset_term_x().
ZOOM_scanset_option_get | ( | ZOOM_scanset | scan, |
const char * | key | ||
) |
Definition at line 1365 of file zoom-c.c.
References ZOOM_options_get().
ZOOM_scanset_option_set | ( | ZOOM_scanset | scan, |
const char * | key, | ||
const char * | val | ||
) |
Definition at line 1371 of file zoom-c.c.
References ZOOM_options_set().
ZOOM_scanset_size | ( | ZOOM_scanset | scan | ) |
Definition at line 1263 of file zoom-c.c.
Referenced by ZOOM_scanset_term_x().
ZOOM_scanset_term | ( | ZOOM_scanset | scan, |
size_t | pos, | ||
size_t * | occ, | ||
size_t * | len | ||
) |
Definition at line 1333 of file zoom-c.c.
References ZOOM_scanset_term_x().