17 #if !defined(GLOBUS_XIO_DRIVER_H)
18 #define GLOBUS_XIO_DRIVER_H 1
21 #include "globus_xio_load.h"
23 #include "globus_xio_types.h"
24 #include "globus_xio.h"
25 #include "globus_xio_util.h"
35 #define GlobusIXIOAttrGetDS(_out_ds, _in_attr, _in_driver) \
39 globus_i_xio_attr_t * _attr; \
40 globus_xio_driver_t _driver; \
41 globus_i_xio_attr_ent_t * _entry; \
45 _driver = (_in_driver); \
47 if(_in_attr == NULL) \
53 _entry = _attr->entry; \
54 for(_ctr = 0; _ctr < _attr->ndx && _ds == NULL; _ctr++) \
56 if(_entry[_ctr].driver == _driver) \
58 _ds = _entry[_ctr].driver_data; \
274 globus_xio_operation_t op,
302 globus_xio_operation_t op,
309 (*globus_xio_driver_push_driver_t)(
310 globus_xio_driver_t driver,
311 globus_xio_stack_t stack);
314 globus_xio_driver_attr_cntl(
315 globus_xio_operation_t op,
316 globus_xio_driver_t driver,
321 globus_xio_driver_data_descriptor_cntl(
322 globus_xio_operation_t op,
323 globus_xio_driver_t driver,
338 globus_xio_driver_handle_t handle,
339 globus_xio_driver_t driver,
347 (*globus_xio_driver_get_driver_t)(
348 globus_xio_driver_t * out_driver);
359 void ** out_driver_attr);
437 const globus_xio_contact_t * contact_info,
438 globus_xio_operation_t op);
466 globus_xio_driver_pass_server_init(
467 globus_xio_operation_t op,
468 const globus_xio_contact_t * contact_info,
469 void * driver_server);
487 void * driver_server);
511 void * driver_server,
512 globus_xio_operation_t op);
515 globus_xio_driver_pass_accept(
516 globus_xio_operation_t op,
524 (*globus_xio_driver_cancel_callback_t)(
525 globus_xio_operation_t op,
527 globus_xio_error_type_t reason);
550 globus_xio_operation_t op,
573 void * driver_server,
582 (*globus_xio_driver_link_cntl_t)(
635 const globus_xio_contact_t * contact_info,
638 globus_xio_operation_t op);
646 const globus_xio_contact_t * contact_info,
649 globus_xio_operation_t op);
681 globus_xio_operation_t op,
682 const globus_xio_contact_t * contact_info,
707 void * driver_handle,
708 globus_xio_operation_t op,
734 globus_xio_operation_t * operation,
735 globus_xio_driver_handle_t handle);
741 globus_xio_driver_operation_destroy(
742 globus_xio_operation_t operation);
748 globus_xio_driver_operation_cancel(
749 globus_xio_driver_handle_t handle,
750 globus_xio_operation_t operation);
762 globus_xio_operation_t operation);
783 globus_xio_driver_merge_handle(
784 globus_xio_operation_t op,
785 globus_xio_driver_handle_t handle);
811 void * driver_handle,
813 globus_xio_operation_t op);
833 globus_xio_operation_t op,
835 void * callback_arg);
854 globus_xio_operation_t op,
885 void * driver_specific_handle,
886 const globus_xio_iovec_t * iovec,
888 globus_xio_operation_t op);
923 globus_xio_operation_t op,
924 globus_xio_iovec_t * iovec,
949 globus_xio_operation_t op,
979 globus_xio_operation_t op);
1005 globus_xio_operation_t op);
1035 void * driver_specific_handle,
1036 const globus_xio_iovec_t * iovec,
1038 globus_xio_operation_t op);
1074 globus_xio_operation_t op,
1075 globus_xio_iovec_t * iovec,
1100 globus_xio_operation_t op,
1130 globus_xio_operation_t top_op,
1131 globus_xio_operation_t bottom_op);
1196 globus_xio_driver_init(
1197 globus_xio_driver_t * driver,
1198 const char * driver_name,
1205 globus_xio_driver_get_user_data(
1206 globus_xio_driver_t in_driver,
1207 void ** out_user_data);
1210 globus_xio_operation_attr_cntl(
1211 globus_xio_operation_t op,
1212 globus_xio_attr_cmd_t cmd,
1219 globus_xio_driver_destroy(
1220 globus_xio_driver_t driver);
1226 globus_xio_driver_set_transport(
1227 globus_xio_driver_t driver,
1238 globus_xio_driver_set_transform(
1239 globus_xio_driver_t driver,
1245 globus_xio_driver_push_driver_t push_driver_func);
1251 globus_xio_driver_set_server(
1252 globus_xio_driver_t driver,
1257 globus_xio_driver_link_cntl_t link_cntl_func,
1262 globus_xio_driver_t driver,
1268 globus_xio_driver_set_attr(
1269 globus_xio_driver_t driver,
1279 globus_xio_operation_block_timeout(
1280 globus_xio_operation_t op);
1283 globus_xio_operation_unblock_timeout(
1284 globus_xio_operation_t op);
1287 globus_xio_operation_refresh_timeout(
1288 globus_xio_operation_t op);
1292 globus_xio_operation_enable_cancel(
1293 globus_xio_operation_t op,
1294 globus_xio_driver_cancel_callback_t cb,
1298 globus_xio_operation_disable_cancel(
1299 globus_xio_operation_t op);
1302 globus_xio_operation_is_canceled(
1303 globus_xio_operation_t op);
1306 globus_xio_operation_get_wait_for(
1307 globus_xio_operation_t op);
1310 globus_xio_operation_get_driver_specific(
1311 globus_xio_operation_t op);
1314 globus_xio_operation_get_user_driver(
1315 globus_xio_operation_t op);
1318 globus_xio_operation_get_transport_user_driver(
1319 globus_xio_operation_t op);
1322 globus_xio_driver_handle_t
1323 globus_xio_operation_get_driver_handle(
1324 globus_xio_operation_t op);
1330 globus_xio_driver_handle_t
1331 globus_xio_operation_get_driver_self_handle(
1332 globus_xio_operation_t op);
1335 globus_xio_operation_get_data_descriptor(
1336 globus_xio_operation_t op,
1340 globus_xio_operation_copy_stack(
1341 globus_xio_operation_t op,
1342 globus_xio_stack_t * stack);
1349 (*globus_xio_string_cntl_parse_func_t)(
1359 typedef struct globus_xio_string_cntl_table_s
1363 globus_xio_string_cntl_parse_func_t parse_func;
1364 } globus_xio_string_cntl_table_t;
1422 globus_xio_driver_t driver,
1423 globus_xio_string_cntl_table_t * table);
1431 globus_xio_driver_t driver,
1432 globus_xio_string_cntl_table_t * table);
1513 globus_xio_string_cntl_formated_off(
1521 globus_xio_string_cntl_formated_int(
1529 globus_xio_string_cntl_string_list(
void globus_xio_driver_finished_accept(globus_xio_operation_t op, void *driver_link, globus_result_t result)
Definition: globus_xio_pass.c:1603
void globus_xio_driver_finished_open(void *driver_handle, globus_xio_operation_t op, globus_result_t result)
Definition: globus_xio_pass.c:156
void(* globus_xio_driver_data_callback_t)(globus_xio_operation_t op, globus_result_t result, globus_size_t nbytes, void *user_arg)
Definition: globus_xio_driver.h:301
globus_result_t(* globus_xio_driver_attr_copy_t)(void **dst, void *src)
Definition: globus_xio_driver.h:369
globus_result_t(* globus_xio_driver_read_t)(void *driver_specific_handle, const globus_xio_iovec_t *iovec, int iovec_count, globus_xio_operation_t op)
Definition: globus_xio_driver.h:884
globus_result_t(* globus_xio_driver_write_t)(void *driver_specific_handle, const globus_xio_iovec_t *iovec, int iovec_count, globus_xio_operation_t op)
Definition: globus_xio_driver.h:1034
globus_result_t(* globus_xio_driver_server_destroy_t)(void *driver_server)
Definition: globus_xio_driver.h:486
globus_result_t globus_xio_driver_handle_string_cntl_set_table(globus_xio_driver_t driver, globus_xio_string_cntl_table_t *table)
Definition: globus_xio_driver.c:2220
globus_result_t(* globus_xio_driver_attr_cntl_t)(void *attr, int cmd, va_list ap)
Definition: globus_xio_driver.h:404
globus_result_t globus_xio_string_cntl_string(void *attr, const char *key, const char *val, int cmd, globus_xio_driver_attr_cntl_t cntl_func)
Definition: globus_xio_attr.c:1428
globus_bool_t globus_xio_driver_eof_received(globus_xio_operation_t op)
Definition: globus_xio_driver.c:1902
globus_result_t(* globus_xio_driver_close_t)(void *driver_handle, void *driver_attr, globus_xio_operation_t op)
Close a handle.
Definition: globus_xio_driver.h:810
int globus_bool_t
Boolean type.
Definition: globus_types.h:93
globus_result_t globus_xio_driver_handle_cntl(globus_xio_driver_handle_t driver_handle, globus_xio_driver_t driver, int cmd,...)
Definition: globus_xio_driver.c:1762
globus_result_t globus_xio_driver_pass_close(globus_xio_operation_t op, globus_xio_driver_callback_t cb, void *callback_arg)
Pass the close operation down the driver stack.
Definition: globus_xio_pass.c:394
globus_result_t globus_xio_driver_pass_read(globus_xio_operation_t op, globus_xio_iovec_t *iovec, int iovec_count, globus_size_t wait_for, globus_xio_driver_data_callback_t cb, void *user_arg)
Definition: globus_xio_pass.c:933
globus_result_t globus_xio_driver_operation_create(globus_xio_operation_t *operation, globus_xio_driver_handle_t driver_handle)
Definition: globus_xio_driver.c:1062
globus_result_t(* globus_xio_driver_transport_open_t)(const globus_xio_contact_t *contact_info, void *driver_link, void *driver_attr, globus_xio_operation_t op)
Open a handle.
Definition: globus_xio_driver.h:645
globus_result_t(* globus_xio_driver_attr_destroy_t)(void *driver_attr)
Definition: globus_xio_driver.h:381
globus_result_t globus_xio_string_cntl_float(void *attr, const char *key, const char *val, int cmd, globus_xio_driver_attr_cntl_t cntl_func)
Definition: globus_xio_attr.c:1400
void(* globus_xio_driver_callback_t)(globus_xio_operation_t op, globus_result_t result, void *user_arg)
Open and Close Callback Signature.
Definition: globus_xio_driver.h:273
globus_result_t(* globus_xio_driver_handle_cntl_t)(void *handle, int cmd, va_list ap)
Definition: globus_xio_driver.h:776
void globus_xio_driver_finished_write(globus_xio_operation_t op, globus_result_t result, globus_size_t nwritten)
Definition: globus_xio_pass.c:759
globus_result_t(* globus_xio_driver_server_init_t)(void *driver_attr, const globus_xio_contact_t *contact_info, globus_xio_operation_t op)
Definition: globus_xio_driver.h:435
globus_result_t(* globus_xio_driver_transform_open_t)(const globus_xio_contact_t *contact_info, void *driver_link, void *driver_attr, globus_xio_operation_t op)
Open a handle.
Definition: globus_xio_driver.h:634
globus_result_t(* globus_xio_driver_link_destroy_t)(void *driver_link)
Definition: globus_xio_driver.h:598
globus_result_t globus_xio_string_cntl_int(void *attr, const char *key, const char *val, int cmd, globus_xio_driver_attr_cntl_t cntl_func)
Definition: globus_xio_attr.c:1323
void globus_xio_driver_finished_close(globus_xio_operation_t op, globus_result_t result)
Definition: globus_xio_pass.c:537
size_t globus_size_t
Standard size of memory objectThe globus_size_t is the size of a memory object. It is identical to si...
Definition: globus_types.h:48
globus_result_t globus_xio_string_cntl_bool(void *attr, const char *key, const char *val, int cmd, globus_xio_driver_attr_cntl_t cntl_func)
Definition: globus_xio_attr.c:1447
globus_result_t globus_xio_driver_pass_open(globus_xio_operation_t op, const globus_xio_contact_t *contact_info, globus_xio_driver_callback_t cb, void *user_arg)
Definition: globus_xio_pass.c:27
globus_bool_t globus_xio_driver_operation_is_blocking(globus_xio_operation_t op)
Definition: globus_xio_driver.c:2340
void globus_xio_driver_finished_read(globus_xio_operation_t op, globus_result_t result, globus_size_t nread)
Definition: globus_xio_pass.c:1120
Headers common to all of Globus.
uint32_t globus_result_t
Definition: globus_types.h:99
globus_result_t(* globus_xio_driver_server_cntl_t)(void *driver_server, int cmd, va_list ap)
Definition: globus_xio_driver.h:572
globus_result_t(* globus_xio_driver_server_accept_t)(void *driver_server, globus_xio_operation_t op)
Definition: globus_xio_driver.h:510
globus_result_t globus_xio_driver_set_server_pre_init(globus_xio_driver_t driver, globus_xio_driver_server_init_t server_pre_init_func)
Server Pre-Init.
Definition: globus_xio_driver.c:2128
globus_result_t globus_xio_string_cntl_int_int(void *attr, const char *key, const char *val, int cmd, globus_xio_driver_attr_cntl_t cntl_func)
Definition: globus_xio_attr.c:1351
globus_result_t globus_xio_string_cntl_bouncer(globus_xio_driver_attr_cntl_t cntl_func, void *attr, int cmd,...)
Definition: globus_xio_attr.c:1190
globus_result_t(* globus_xio_driver_attr_init_t)(void **out_driver_attr)
Definition: globus_xio_driver.h:358
void globus_xio_driver_set_eof_received(globus_xio_operation_t op)
Definition: globus_xio_driver.c:1867
globus_result_t globus_xio_driver_string_cntl_set_table(globus_xio_driver_t driver, globus_xio_string_cntl_table_t *table)
Definition: globus_xio_driver.c:2190
globus_result_t globus_xio_driver_merge_operation(globus_xio_operation_t top_op, globus_xio_operation_t bottom_op)
globus_result_t globus_xio_driver_pass_write(globus_xio_operation_t op, globus_xio_iovec_t *iovec, int iovec_count, globus_size_t wait_for, globus_xio_driver_data_callback_t cb, void *user_arg)
Definition: globus_xio_pass.c:610