Operation data: one field for each op type (except SEND_CLOSE_FROM_CLIENT which has no arguments)
More...
|
grpc_op_type | op |
| Operation type, as defined by grpc_op_type. More...
|
|
gpr_uint32 | flags |
| Write flags bitset for grpc_begin_messages. More...
|
|
void * | reserved |
| Reserved for future usage. More...
|
|
union { |
struct { |
void * reserved [8] |
|
} reserved |
| Reserved for future usage. More...
|
|
struct { |
size_t count |
|
grpc_metadata * metadata |
|
} send_initial_metadata |
|
grpc_byte_buffer * send_message |
|
struct { |
size_t trailing_metadata_count |
|
grpc_metadata * trailing_metadata |
|
grpc_status_code status |
|
const char * status_details |
|
} send_status_from_server |
|
grpc_metadata_array * recv_initial_metadata |
| ownership of the array is with the caller, but ownership of the elements stays with the call object (ie key, value members are owned by the call object, recv_initial_metadata->array is owned by the caller). More...
|
|
grpc_byte_buffer ** recv_message |
| ownership of the byte buffer is moved to the caller; the caller must call grpc_byte_buffer_destroy on this value, or reuse it in a future op. More...
|
|
struct { |
grpc_metadata_array * trailing_metadata |
| ownership of the array is with the caller, but ownership of the elements stays with the call object (ie key, value members are owned by the call object, trailing_metadata->array is owned by the caller). More...
|
|
grpc_status_code * status |
|
char ** status_details |
| status_details is a buffer owned by the application before the op completes and after the op has completed. More...
|
|
size_t * status_details_capacity |
|
} recv_status_on_client |
|
struct { |
int * cancelled |
| out argument, set to 1 if the call failed in any way (seen as a cancellation on the server), or 0 if the call succeeded More...
|
|
} recv_close_on_server |
|
} | data |
|
Operation data: one field for each op type (except SEND_CLOSE_FROM_CLIENT which has no arguments)
ownership of the array is with the caller, but ownership of the elements stays with the call object (ie key, value members are owned by the call object, recv_initial_metadata->array is owned by the caller).
After the operation completes, call grpc_metadata_array_destroy on this value, or reuse it in a future op.
char** grpc_op::status_details |
status_details is a buffer owned by the application before the op completes and after the op has completed.
During the operation status_details may be reallocated to a size larger than status_details_capacity, in which case *status_details_capacity will be updated with the new array capacity.
Pre-allocating space: size_t my_capacity = 8; char *my_details = gpr_malloc(my_capacity); x.status_details = x.status_details_capacity =
Not pre-allocating space: size_t my_capacity = 0; char *my_details = NULL; x.status_details = x.status_details_capacity =
After the call: gpr_free(my_details);
ownership of the array is with the caller, but ownership of the elements stays with the call object (ie key, value members are owned by the call object, trailing_metadata->array is owned by the caller).
After the operation completes, call grpc_metadata_array_destroy on this value, or reuse it in a future op.