17 #if !defined(GLOBUS_XIO_DRIVER_H)
18 #define GLOBUS_XIO_DRIVER_H 1
20 #include "globus_common.h"
21 #include "globus_xio_load.h"
22 #include "globus_common.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,
275 globus_result_t result,
302 globus_xio_operation_t op,
303 globus_result_t result,
304 globus_size_t nbytes,
308 typedef globus_result_t
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,
346 typedef globus_result_t
347 (*globus_xio_driver_get_driver_t)(
348 globus_xio_driver_t * out_driver);
357 typedef globus_result_t
359 void ** out_driver_attr);
368 typedef globus_result_t
380 typedef globus_result_t
403 typedef globus_result_t
434 typedef globus_result_t
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);
482 typedef globus_result_t
484 void * driver_server);
506 typedef globus_result_t
508 void * driver_server,
509 globus_xio_operation_t op);
512 globus_xio_driver_pass_accept(
513 globus_xio_operation_t op,
521 (*globus_xio_driver_cancel_callback_t)(
522 globus_xio_operation_t op,
524 globus_xio_error_type_t reason);
547 globus_xio_operation_t op,
549 globus_result_t result);
568 typedef globus_result_t
570 void * driver_server,
578 typedef globus_result_t
579 (*globus_xio_driver_link_cntl_t)(
594 typedef globus_result_t
630 typedef globus_result_t
632 const globus_xio_contact_t * contact_info,
635 globus_xio_operation_t op);
641 typedef globus_result_t
643 const globus_xio_contact_t * contact_info,
646 globus_xio_operation_t op);
678 globus_xio_operation_t op,
679 const globus_xio_contact_t * contact_info,
704 void * driver_handle,
705 globus_xio_operation_t op,
706 globus_result_t result);
731 globus_xio_operation_t * operation,
732 globus_xio_driver_handle_t handle);
738 globus_xio_driver_operation_destroy(
739 globus_xio_operation_t operation);
745 globus_xio_driver_operation_cancel(
746 globus_xio_driver_handle_t handle,
747 globus_xio_operation_t operation);
759 globus_xio_operation_t operation);
772 typedef globus_result_t
780 globus_xio_driver_merge_handle(
781 globus_xio_operation_t op,
782 globus_xio_driver_handle_t handle);
806 typedef globus_result_t
808 void * driver_specific_handle,
810 globus_xio_operation_t op);
830 globus_xio_operation_t op,
832 void * callback_arg);
851 globus_xio_operation_t op,
852 globus_result_t result);
880 typedef globus_result_t
882 void * driver_specific_handle,
883 const globus_xio_iovec_t * iovec,
885 globus_xio_operation_t op);
920 globus_xio_operation_t op,
921 globus_xio_iovec_t * iovec,
923 globus_size_t wait_for,
946 globus_xio_operation_t op,
947 globus_result_t result,
948 globus_size_t nread);
976 globus_xio_operation_t op);
1002 globus_xio_operation_t op);
1030 typedef globus_result_t
1032 void * driver_specific_handle,
1033 const globus_xio_iovec_t * iovec,
1035 globus_xio_operation_t op);
1071 globus_xio_operation_t op,
1072 globus_xio_iovec_t * iovec,
1074 globus_size_t wait_for,
1097 globus_xio_operation_t op,
1098 globus_result_t result,
1099 globus_size_t nwritten);
1127 globus_xio_operation_t top_op,
1128 globus_xio_operation_t bottom_op);
1193 globus_xio_driver_init(
1194 globus_xio_driver_t * driver,
1195 const char * driver_name,
1202 globus_xio_driver_get_user_data(
1203 globus_xio_driver_t in_driver,
1204 void ** out_user_data);
1207 globus_xio_operation_attr_cntl(
1208 globus_xio_operation_t op,
1209 globus_xio_attr_cmd_t cmd,
1216 globus_xio_driver_destroy(
1217 globus_xio_driver_t driver);
1223 globus_xio_driver_set_transport(
1224 globus_xio_driver_t driver,
1235 globus_xio_driver_set_transform(
1236 globus_xio_driver_t driver,
1242 globus_xio_driver_push_driver_t push_driver_func);
1248 globus_xio_driver_set_server(
1249 globus_xio_driver_t driver,
1254 globus_xio_driver_link_cntl_t link_cntl_func,
1259 globus_xio_driver_t driver,
1265 globus_xio_driver_set_attr(
1266 globus_xio_driver_t driver,
1276 globus_xio_operation_block_timeout(
1277 globus_xio_operation_t op);
1280 globus_xio_operation_unblock_timeout(
1281 globus_xio_operation_t op);
1284 globus_xio_operation_refresh_timeout(
1285 globus_xio_operation_t op);
1289 globus_xio_operation_enable_cancel(
1290 globus_xio_operation_t op,
1291 globus_xio_driver_cancel_callback_t cb,
1295 globus_xio_operation_disable_cancel(
1296 globus_xio_operation_t op);
1299 globus_xio_operation_is_canceled(
1300 globus_xio_operation_t op);
1303 globus_xio_operation_get_wait_for(
1304 globus_xio_operation_t op);
1307 globus_xio_operation_get_driver_specific(
1308 globus_xio_operation_t op);
1311 globus_xio_operation_get_user_driver(
1312 globus_xio_operation_t op);
1315 globus_xio_operation_get_transport_user_driver(
1316 globus_xio_operation_t op);
1319 globus_xio_driver_handle_t
1320 globus_xio_operation_get_driver_handle(
1321 globus_xio_operation_t op);
1327 globus_xio_driver_handle_t
1328 globus_xio_operation_get_driver_self_handle(
1329 globus_xio_operation_t op);
1332 globus_xio_operation_get_data_descriptor(
1333 globus_xio_operation_t op,
1334 globus_bool_t force_create);
1337 globus_xio_operation_copy_stack(
1338 globus_xio_operation_t op,
1339 globus_xio_stack_t * stack);
1345 typedef globus_result_t
1346 (*globus_xio_string_cntl_parse_func_t)(
1356 typedef struct globus_xio_string_cntl_table_s
1360 globus_xio_string_cntl_parse_func_t parse_func;
1361 } globus_xio_string_cntl_table_t;
1419 globus_xio_driver_t driver,
1420 globus_xio_string_cntl_table_t * table);
1428 globus_xio_driver_t driver,
1429 globus_xio_string_cntl_table_t * table);
1510 globus_xio_string_cntl_formated_off(
1518 globus_xio_string_cntl_formated_int(
1526 globus_xio_string_cntl_string_list(