Public Member Functions | Private Member Functions | Friends | List of all members
grpc::ChannelInterface Class Referenceabstract

Codegen interface for grpc::Channel. More...

#include <channel_interface.h>

Inheritance diagram for grpc::ChannelInterface:
Inheritance graph
[legend]

Public Member Functions

virtual grpc_connectivity_state GetState (bool try_to_connect)=0
 
template<typename T >
void NotifyOnStateChange (grpc_connectivity_state last_observed, T deadline, grpc::CompletionQueue *cq, void *tag)
 
template<typename T >
bool WaitForConnected (T deadline)
 Wait for this channel to be connected. More...
 
template<typename T >
bool WaitForStateChange (grpc_connectivity_state last_observed, T deadline)
 
virtual ~ChannelInterface ()
 

Private Member Functions

virtual grpc::CompletionQueueCallbackCQ ()
 
virtual internal::Call CreateCall (const internal::RpcMethod &method, grpc::ClientContext *context, grpc::CompletionQueue *cq)=0
 
virtual internal::Call CreateCallInternal (const internal::RpcMethod &, grpc::ClientContext *, grpc::CompletionQueue *, size_t)
 
virtual void NotifyOnStateChangeImpl (grpc_connectivity_state last_observed, gpr_timespec deadline, grpc::CompletionQueue *cq, void *tag)=0
 
virtual void PerformOpsOnCall (internal::CallOpSetInterface *ops, internal::Call *call)=0
 
virtual void * RegisterMethod (const char *method)=0
 
virtual bool WaitForStateChangeImpl (grpc_connectivity_state last_observed, gpr_timespec deadline)=0
 

Friends

template<class R >
class grpc::ClientReader
 
template<class W , class R >
class grpc::ClientReaderWriter
 
template<class W >
class grpc::ClientWriter
 
class grpc::experimental::DelegatingChannel
 
template<class InputMessage , class OutputMessage >
class grpc::internal::BlockingUnaryCallImpl
 
template<class InputMessage , class OutputMessage >
class grpc::internal::CallbackUnaryCallImpl
 
template<class R >
class grpc::internal::ClientAsyncReaderFactory
 
template<class W , class R >
class grpc::internal::ClientAsyncReaderWriterFactory
 
class grpc::internal::ClientAsyncResponseReaderHelper
 
template<class W >
class grpc::internal::ClientAsyncWriterFactory
 
template<class R >
class grpc::internal::ClientCallbackReaderFactory
 
template<class W , class R >
class grpc::internal::ClientCallbackReaderWriterFactory
 
class grpc::internal::ClientCallbackUnaryFactory
 
template<class W >
class grpc::internal::ClientCallbackWriterFactory
 
class grpc::internal::InterceptedChannel
 
class grpc::internal::RpcMethod
 

Detailed Description

Codegen interface for grpc::Channel.

Definition at line 73 of file grpcpp/impl/codegen/channel_interface.h.

Constructor & Destructor Documentation

◆ ~ChannelInterface()

virtual grpc::ChannelInterface::~ChannelInterface ( )
inlinevirtual

Definition at line 75 of file grpcpp/impl/codegen/channel_interface.h.

Member Function Documentation

◆ CallbackCQ()

virtual grpc::CompletionQueue* grpc::ChannelInterface::CallbackCQ ( )
inlineprivatevirtual

◆ CreateCall()

virtual internal::Call grpc::ChannelInterface::CreateCall ( const internal::RpcMethod method,
grpc::ClientContext context,
grpc::CompletionQueue cq 
)
privatepure virtual

◆ CreateCallInternal()

virtual internal::Call grpc::ChannelInterface::CreateCallInternal ( const internal::RpcMethod ,
grpc::ClientContext ,
grpc::CompletionQueue ,
size_t   
)
inlineprivatevirtual

◆ GetState()

virtual grpc_connectivity_state grpc::ChannelInterface::GetState ( bool  try_to_connect)
pure virtual

Get the current channel state. If the channel is in IDLE and try_to_connect is set to true, try to connect.

Implemented in grpc::Channel, grpc::internal::InterceptedChannel, and grpc::experimental::DelegatingChannel.

◆ NotifyOnStateChange()

template<typename T >
void grpc::ChannelInterface::NotifyOnStateChange ( grpc_connectivity_state  last_observed,
T  deadline,
grpc::CompletionQueue cq,
void *  tag 
)
inline

Return the tag on cq when the channel state is changed or deadline expires. GetState needs to called to get the current state.

Definition at line 83 of file grpcpp/impl/codegen/channel_interface.h.

◆ NotifyOnStateChangeImpl()

virtual void grpc::ChannelInterface::NotifyOnStateChangeImpl ( grpc_connectivity_state  last_observed,
gpr_timespec  deadline,
grpc::CompletionQueue cq,
void *  tag 
)
privatepure virtual

◆ PerformOpsOnCall()

virtual void grpc::ChannelInterface::PerformOpsOnCall ( internal::CallOpSetInterface ops,
internal::Call call 
)
privatepure virtual

◆ RegisterMethod()

virtual void* grpc::ChannelInterface::RegisterMethod ( const char *  method)
privatepure virtual

◆ WaitForConnected()

template<typename T >
bool grpc::ChannelInterface::WaitForConnected ( T  deadline)
inline

Wait for this channel to be connected.

Definition at line 99 of file grpcpp/impl/codegen/channel_interface.h.

◆ WaitForStateChange()

template<typename T >
bool grpc::ChannelInterface::WaitForStateChange ( grpc_connectivity_state  last_observed,
T  deadline 
)
inline

Blocking wait for channel state change or deadline expiration. GetState needs to called to get the current state.

Definition at line 92 of file grpcpp/impl/codegen/channel_interface.h.

◆ WaitForStateChangeImpl()

virtual bool grpc::ChannelInterface::WaitForStateChangeImpl ( grpc_connectivity_state  last_observed,
gpr_timespec  deadline 
)
privatepure virtual

Friends And Related Function Documentation

◆ grpc::ClientReader

template<class R >
friend class grpc::ClientReader
friend

Definition at line 109 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::ClientReaderWriter

template<class W , class R >
friend class grpc::ClientReaderWriter
friend

Definition at line 113 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::ClientWriter

template<class W >
friend class grpc::ClientWriter
friend

Definition at line 111 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::experimental::DelegatingChannel

Definition at line 133 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::BlockingUnaryCallImpl

template<class InputMessage , class OutputMessage >
friend class grpc::internal::BlockingUnaryCallImpl
friend

Definition at line 129 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::CallbackUnaryCallImpl

template<class InputMessage , class OutputMessage >
friend class grpc::internal::CallbackUnaryCallImpl
friend

Definition at line 131 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::ClientAsyncReaderFactory

template<class R >
friend class grpc::internal::ClientAsyncReaderFactory
friend

Definition at line 115 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::ClientAsyncReaderWriterFactory

template<class W , class R >
friend class grpc::internal::ClientAsyncReaderWriterFactory
friend

Definition at line 119 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::ClientAsyncResponseReaderHelper

Definition at line 120 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::ClientAsyncWriterFactory

template<class W >
friend class grpc::internal::ClientAsyncWriterFactory
friend

Definition at line 117 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::ClientCallbackReaderFactory

template<class R >
friend class grpc::internal::ClientCallbackReaderFactory
friend

Definition at line 124 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::ClientCallbackReaderWriterFactory

template<class W , class R >
friend class grpc::internal::ClientCallbackReaderWriterFactory
friend

Definition at line 122 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::ClientCallbackUnaryFactory

Definition at line 127 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::ClientCallbackWriterFactory

template<class W >
friend class grpc::internal::ClientCallbackWriterFactory
friend

Definition at line 126 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::InterceptedChannel

Definition at line 134 of file grpcpp/impl/codegen/channel_interface.h.

◆ grpc::internal::RpcMethod

friend class grpc::internal::RpcMethod
friend

Definition at line 132 of file grpcpp/impl/codegen/channel_interface.h.


The documentation for this class was generated from the following file:


grpc
Author(s):
autogenerated on Fri May 16 2025 03:03:30