|
|
@ -153,7 +153,9 @@ static void shutdown_and_destroy(grpc_completion_queue* cc) { |
|
|
|
// Tag completion queue iterate times
|
|
|
|
// Tag completion queue iterate times
|
|
|
|
class TagCallback : public grpc_experimental_completion_queue_functor { |
|
|
|
class TagCallback : public grpc_experimental_completion_queue_functor { |
|
|
|
public: |
|
|
|
public: |
|
|
|
TagCallback(int* iter) : iter_(iter) { functor_run = &TagCallback::Run; } |
|
|
|
explicit TagCallback(int* iter) : iter_(iter) { |
|
|
|
|
|
|
|
functor_run = &TagCallback::Run; |
|
|
|
|
|
|
|
} |
|
|
|
~TagCallback() {} |
|
|
|
~TagCallback() {} |
|
|
|
static void Run(grpc_experimental_completion_queue_functor* cb, int ok) { |
|
|
|
static void Run(grpc_experimental_completion_queue_functor* cb, int ok) { |
|
|
|
GPR_ASSERT(static_cast<bool>(ok)); |
|
|
|
GPR_ASSERT(static_cast<bool>(ok)); |
|
|
@ -167,7 +169,7 @@ class TagCallback : public grpc_experimental_completion_queue_functor { |
|
|
|
// Check if completion queue is shut down
|
|
|
|
// Check if completion queue is shut down
|
|
|
|
class ShutdownCallback : public grpc_experimental_completion_queue_functor { |
|
|
|
class ShutdownCallback : public grpc_experimental_completion_queue_functor { |
|
|
|
public: |
|
|
|
public: |
|
|
|
ShutdownCallback(bool* done) : done_(done) { |
|
|
|
explicit ShutdownCallback(bool* done) : done_(done) { |
|
|
|
functor_run = &ShutdownCallback::Run; |
|
|
|
functor_run = &ShutdownCallback::Run; |
|
|
|
} |
|
|
|
} |
|
|
|
~ShutdownCallback() {} |
|
|
|
~ShutdownCallback() {} |
|
|
|