|
|
|
@ -48,22 +48,21 @@ |
|
|
|
|
|
|
|
|
|
typedef struct grpc_handshaker grpc_handshaker; |
|
|
|
|
|
|
|
|
|
typedef void (*grpc_handshaker_done_cb)( |
|
|
|
|
grpc_exec_ctx* exec_ctx, grpc_endpoint* endpoint, void* arg); |
|
|
|
|
typedef void (*grpc_handshaker_done_cb)(grpc_exec_ctx* exec_ctx, |
|
|
|
|
grpc_endpoint* endpoint, void* arg); |
|
|
|
|
|
|
|
|
|
struct grpc_handshaker_vtable { |
|
|
|
|
void (*destroy)(grpc_exec_ctx* exec_ctx, grpc_handshaker* handshaker); |
|
|
|
|
|
|
|
|
|
void (*shutdown)(grpc_exec_ctx* exec_ctx, grpc_handshaker* handshaker); |
|
|
|
|
|
|
|
|
|
void (*do_handshake)( |
|
|
|
|
grpc_exec_ctx* exec_ctx, grpc_handshaker* handshaker, |
|
|
|
|
grpc_endpoint* endpoint, gpr_timespec deadline, |
|
|
|
|
grpc_handshaker_done_cb cb, void* arg); |
|
|
|
|
void (*do_handshake)(grpc_exec_ctx* exec_ctx, grpc_handshaker* handshaker, |
|
|
|
|
grpc_endpoint* endpoint, gpr_timespec deadline, |
|
|
|
|
grpc_handshaker_done_cb cb, void* arg); |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
struct grpc_handshaker { |
|
|
|
|
const struct grpc_handshaker_vtable *vtable; |
|
|
|
|
const struct grpc_handshaker_vtable* vtable; |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
// Called by concrete implementations to initialize the base struct.
|
|
|
|
@ -75,10 +74,11 @@ void grpc_handshaker_destroy(grpc_exec_ctx* exec_ctx, |
|
|
|
|
grpc_handshaker* handshaker); |
|
|
|
|
void grpc_handshaker_shutdown(grpc_exec_ctx* exec_ctx, |
|
|
|
|
grpc_handshaker* handshaker); |
|
|
|
|
void grpc_handshaker_do_handshake( |
|
|
|
|
grpc_exec_ctx* exec_ctx, grpc_handshaker* handshaker, |
|
|
|
|
grpc_endpoint* endpoint, gpr_timespec deadline, |
|
|
|
|
grpc_handshaker_done_cb cb, void* arg); |
|
|
|
|
void grpc_handshaker_do_handshake(grpc_exec_ctx* exec_ctx, |
|
|
|
|
grpc_handshaker* handshaker, |
|
|
|
|
grpc_endpoint* endpoint, |
|
|
|
|
gpr_timespec deadline, |
|
|
|
|
grpc_handshaker_done_cb cb, void* arg); |
|
|
|
|
|
|
|
|
|
//
|
|
|
|
|
// grpc_handshake_manager -- manages a set of handshakers
|
|
|
|
@ -92,15 +92,16 @@ grpc_handshake_manager* grpc_handshake_manager_create(); |
|
|
|
|
void grpc_handshake_manager_add(grpc_handshaker* handshaker, |
|
|
|
|
grpc_handshake_manager* mgr); |
|
|
|
|
|
|
|
|
|
void grpc_handshake_manager_destroy( |
|
|
|
|
grpc_exec_ctx* exec_ctx, grpc_handshake_manager* mgr); |
|
|
|
|
void grpc_handshake_manager_destroy(grpc_exec_ctx* exec_ctx, |
|
|
|
|
grpc_handshake_manager* mgr); |
|
|
|
|
|
|
|
|
|
void grpc_handshake_manager_shutdown( |
|
|
|
|
grpc_exec_ctx* exec_ctx, grpc_handshake_manager* mgr); |
|
|
|
|
void grpc_handshake_manager_shutdown(grpc_exec_ctx* exec_ctx, |
|
|
|
|
grpc_handshake_manager* mgr); |
|
|
|
|
|
|
|
|
|
void grpc_handshake_manager_do_handshake( |
|
|
|
|
grpc_exec_ctx* exec_ctx, grpc_handshake_manager* mgr, |
|
|
|
|
grpc_endpoint* endpoint, gpr_timespec deadline, |
|
|
|
|
grpc_handshaker_done_cb cb, void* arg); |
|
|
|
|
void grpc_handshake_manager_do_handshake(grpc_exec_ctx* exec_ctx, |
|
|
|
|
grpc_handshake_manager* mgr, |
|
|
|
|
grpc_endpoint* endpoint, |
|
|
|
|
gpr_timespec deadline, |
|
|
|
|
grpc_handshaker_done_cb cb, void* arg); |
|
|
|
|
|
|
|
|
|
#endif /* GRPC_CORE_LIB_CHANNEL_HANDSHAKER_H */ |
|
|
|
|