GRPC C++  1.13.0-dev
Public Member Functions | Protected Member Functions | Friends
grpc::ChannelCredentials Class Referenceabstract

A channel credentials object encapsulates all the state needed by a client to authenticate with a server for a given channel. More...

#include <credentials.h>

Public Member Functions

 ChannelCredentials ()
 
 ~ChannelCredentials ()
 

Protected Member Functions

virtual SecureChannelCredentials * AsSecureCredentials ()=0
 

Friends

std::shared_ptr< ChannelCredentialsCompositeChannelCredentials (const std::shared_ptr< ChannelCredentials > &channel_creds, const std::shared_ptr< CallCredentials > &call_creds)
 Combines a channel credentials and a call credentials into a composite channel credentials. More...
 
std::shared_ptr< ChannelCreateCustomChannel (const grpc::string &target, const std::shared_ptr< ChannelCredentials > &creds, const ChannelArguments &args)
 Create a new custom Channel pointing to target. More...
 

Detailed Description

A channel credentials object encapsulates all the state needed by a client to authenticate with a server for a given channel.

It can make various assertions, e.g., about the client’s identity, role for all the calls on that channel.

See also
https://grpc.io/docs/guides/auth.html

Constructor & Destructor Documentation

◆ ChannelCredentials()

grpc::ChannelCredentials::ChannelCredentials ( )

◆ ~ChannelCredentials()

grpc::ChannelCredentials::~ChannelCredentials ( )

Member Function Documentation

◆ AsSecureCredentials()

virtual SecureChannelCredentials* grpc::ChannelCredentials::AsSecureCredentials ( )
protectedpure virtual

Friends And Related Function Documentation

◆ CompositeChannelCredentials

std::shared_ptr<ChannelCredentials> CompositeChannelCredentials ( const std::shared_ptr< ChannelCredentials > &  channel_creds,
const std::shared_ptr< CallCredentials > &  call_creds 
)
friend

Combines a channel credentials and a call credentials into a composite channel credentials.

◆ CreateCustomChannel

std::shared_ptr<Channel> CreateCustomChannel ( const grpc::string target,
const std::shared_ptr< ChannelCredentials > &  creds,
const ChannelArguments args 
)
friend

Create a new custom Channel pointing to target.

Warning
For advanced use and testing ONLY. Override default channel arguments only if necessary.
Parameters
targetThe URI of the endpoint to connect to.
credsCredentials to use for the created channel. If it does not hold an object or is invalid, a lame channel (one on which all operations fail) is returned.
argsOptions for channel creation.

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