Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
grpc::internal::RpcServiceMethod Class Reference

Server side rpc method class. More...

#include <rpc_service_method.h>

Inheritance diagram for grpc::internal::RpcServiceMethod:
Inheritance graph
[legend]

Public Types

enum  ApiType {
  ApiType::SYNC, ApiType::ASYNC, ApiType::RAW, ApiType::CALL_BACK,
  ApiType::RAW_CALL_BACK
}
 
- Public Types inherited from grpc::internal::RpcMethod
enum  RpcType { NORMAL_RPC = 0, CLIENT_STREAMING, SERVER_STREAMING, BIDI_STREAMING }
 

Public Member Functions

ApiType api_type () const
 
MethodHandlerhandler () const
 if MethodHandler is nullptr, then this is an async method More...
 
 RpcServiceMethod (const char *name, RpcMethod::RpcType type, MethodHandler *handler)
 Takes ownership of the handler. More...
 
void * server_tag () const
 
void set_server_tag (void *tag)
 
void SetHandler (MethodHandler *handler)
 
void SetServerApiType (RpcServiceMethod::ApiType type)
 
- Public Member Functions inherited from grpc::internal::RpcMethod
void * channel_tag () const
 
RpcType method_type () const
 
const char * name () const
 
 RpcMethod (const char *name, const char *suffix_for_stats, RpcType type)
 
 RpcMethod (const char *name, const char *suffix_for_stats, RpcType type, const std::shared_ptr< ChannelInterface > &channel)
 
 RpcMethod (const char *name, RpcType type)
 
 RpcMethod (const char *name, RpcType type, const std::shared_ptr< ChannelInterface > &channel)
 
void SetMethodType (RpcType type)
 
const char * suffix_for_stats () const
 

Private Member Functions

const char * TypeToString (RpcServiceMethod::ApiType type)
 

Private Attributes

ApiType api_type_
 
std::unique_ptr< MethodHandlerhandler_
 
void * server_tag_
 

Detailed Description

Server side rpc method class.

Definition at line 86 of file grpcpp/impl/codegen/rpc_service_method.h.

Member Enumeration Documentation

◆ ApiType

Enumerator
SYNC 
ASYNC 
RAW 
CALL_BACK 
RAW_CALL_BACK 

Definition at line 96 of file grpcpp/impl/codegen/rpc_service_method.h.

Constructor & Destructor Documentation

◆ RpcServiceMethod()

grpc::internal::RpcServiceMethod::RpcServiceMethod ( const char *  name,
RpcMethod::RpcType  type,
MethodHandler handler 
)
inline

Takes ownership of the handler.

Definition at line 89 of file grpcpp/impl/codegen/rpc_service_method.h.

Member Function Documentation

◆ api_type()

ApiType grpc::internal::RpcServiceMethod::api_type ( ) const
inline

Definition at line 108 of file grpcpp/impl/codegen/rpc_service_method.h.

◆ handler()

MethodHandler* grpc::internal::RpcServiceMethod::handler ( ) const
inline

if MethodHandler is nullptr, then this is an async method

Definition at line 107 of file grpcpp/impl/codegen/rpc_service_method.h.

◆ server_tag()

void* grpc::internal::RpcServiceMethod::server_tag ( ) const
inline

Definition at line 105 of file grpcpp/impl/codegen/rpc_service_method.h.

◆ set_server_tag()

void grpc::internal::RpcServiceMethod::set_server_tag ( void *  tag)
inline

Definition at line 104 of file grpcpp/impl/codegen/rpc_service_method.h.

◆ SetHandler()

void grpc::internal::RpcServiceMethod::SetHandler ( MethodHandler handler)
inline

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

◆ SetServerApiType()

void grpc::internal::RpcServiceMethod::SetServerApiType ( RpcServiceMethod::ApiType  type)
inline

Definition at line 110 of file grpcpp/impl/codegen/rpc_service_method.h.

◆ TypeToString()

const char* grpc::internal::RpcServiceMethod::TypeToString ( RpcServiceMethod::ApiType  type)
inlineprivate

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

Member Data Documentation

◆ api_type_

ApiType grpc::internal::RpcServiceMethod::api_type_
private

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

◆ handler_

std::unique_ptr<MethodHandler> grpc::internal::RpcServiceMethod::handler_
private

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

◆ server_tag_

void* grpc::internal::RpcServiceMethod::server_tag_
private

Definition at line 130 of file grpcpp/impl/codegen/rpc_service_method.h.


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


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