Instance Methods | Properties | List of all members
GRPCCallOptions Class Reference

#import <GRPCCallOptions.h>

Inheritance diagram for GRPCCallOptions:
Inheritance graph
[legend]

Instance Methods

(BOOL- hasChannelOptionsEqualTo:
 

Properties

GRPCMetadataDictionaryadditionalChannelArgs
 
id< GRPCAuthorizationProtocolauthTokenProvider
 
NSUInteger channelID
 
NSUInteger channelOptionsHash
 
NSString * channelPoolDomain
 
GRPCCompressionAlgorithm compressionAlgorithm
 
NSTimeInterval connectInitialBackoff
 
NSTimeInterval connectMaxBackoff
 
NSTimeInterval connectMinTimeout
 
BOOL flowControlEnabled
 
NSString * hostNameOverride
 
GRPCMetadataDictionaryinitialMetadata
 
NSArray< id< GRPCInterceptorFactory > > * interceptorFactories
 
NSTimeInterval keepaliveInterval
 
NSTimeInterval keepaliveTimeout
 
id logContext [implementation]
 
NSTimeInterval maxRetryInterval
 
NSTimeInterval minRetryInterval
 
NSString * oauth2AccessToken
 
NSString * PEMCertificateChain
 
NSString * PEMPrivateKey
 
NSString * PEMRootCertificates
 
NSUInteger responseSizeLimit
 
BOOL retryEnabled
 
double retryFactor
 
NSString * serverAuthority
 
NSTimeInterval timeout
 
GRPCTransportID transport
 
GRPCTransportType transportType
 
NSString * userAgentPrefix
 
NSString * userAgentSuffix
 

Detailed Description

Immutable user configurable options for a gRPC call. Caller can obtain a mutable copy of type GRPCMutableCallOptions by calling [option mutableCopy]

Definition at line 32 of file GRPCCallOptions.h.

Method Documentation

◆ hasChannelOptionsEqualTo:

- (BOOL) hasChannelOptionsEqualTo: (GRPCCallOptions *)  callOptions

Return if the channel options are equal to another object.

Property Documentation

◆ additionalChannelArgs

- (GRPCMetadataDictionary*) additionalChannelArgs
readnonatomiccopy

Specify channel args to be used for this call. For a list of channel args available, see grpc/grpc_types.h

Definition at line 159 of file GRPCCallOptions.h.

◆ authTokenProvider

- (id<GRPCAuthorizationProtocol>) authTokenProvider
readnonatomicassign

The interface to get the OAuth2 access token string. gRPC will attempt to acquire token when initiating the call. This parameter should not be used simultaneously with oauth2AccessToken.

Definition at line 81 of file GRPCCallOptions.h.

◆ channelID

- (NSUInteger) channelID
readnonatomicassign

Channel id allows control of channel caching within a channelPoolDomain. A call with a unique channelID will create a new channel (connection) instead of reusing an existing one. Multiple calls in the same channelPoolDomain using identical channelID are allowed to share connection if other channel options are also the same.

Definition at line 214 of file GRPCCallOptions.h.

◆ channelOptionsHash

- (NSUInteger) channelOptionsHash
readnonatomicassign

Hash for channel options.

Definition at line 219 of file GRPCCallOptions.h.

◆ channelPoolDomain

- (NSString*) channelPoolDomain
readnonatomiccopy

A string that specify the domain where channel is being cached. Channels with different domains will not get cached to the same connection.

Definition at line 206 of file GRPCCallOptions.h.

◆ compressionAlgorithm

- (GRPCCompressionAlgorithm) compressionAlgorithm
readnonatomicassign

The compression algorithm to be used by the gRPC call. For more details refer to https://github.com/grpc/grpc/blob/master/doc/compression.md

Definition at line 114 of file GRPCCallOptions.h.

◆ connectInitialBackoff

- (NSTimeInterval) connectInitialBackoff
readnonatomicassign

Definition at line 152 of file GRPCCallOptions.h.

◆ connectMaxBackoff

- (NSTimeInterval) connectMaxBackoff
readnonatomicassign

Definition at line 153 of file GRPCCallOptions.h.

◆ connectMinTimeout

- (NSTimeInterval) connectMinTimeout
readnonatomicassign

Definition at line 151 of file GRPCCallOptions.h.

◆ flowControlEnabled

- (BOOL) flowControlEnabled
readnonatomicassign

Enable flow control of a gRPC call. The option is default to NO. If set to YES, writeData: method should only be called at most once before a didWriteData callback is issued, and receiveNextMessage: must be called each time before gRPC call issues a didReceiveMessage callback.

Definition at line 58 of file GRPCCallOptions.h.

◆ hostNameOverride

- (NSString*) hostNameOverride
readnonatomiccopy

Override the hostname during the TLS hostname validation process.

Definition at line 200 of file GRPCCallOptions.h.

◆ initialMetadata

- (GRPCMetadataDictionary*) initialMetadata
readnonatomiccopy

Initial metadata key-value pairs that should be included in the request. Dictionary key is of type NSString, value should be either NSString or NSData containing binary bytes data.

Definition at line 88 of file GRPCCallOptions.h.

◆ interceptorFactories

- (NSArray<id<GRPCInterceptorFactory> >*) interceptorFactories
readnonatomiccopy

An array of interceptor factories. When a call starts, interceptors are created by these factories and chained together with the same order as the factories in this array. This parameter should not be modified by any interceptor and will not take effect if done so.

Definition at line 66 of file GRPCCallOptions.h.

◆ keepaliveInterval

- (NSTimeInterval) keepaliveInterval
readnonatomicassign

Definition at line 145 of file GRPCCallOptions.h.

◆ keepaliveTimeout

- (NSTimeInterval) keepaliveTimeout
readnonatomicassign

Definition at line 146 of file GRPCCallOptions.h.

◆ logContext

- (id) logContext
readatomicassignimplementation

Parameter used for internal logging.

Definition at line 28 of file GRPCCallOptions+Internal.h.

◆ maxRetryInterval

- (NSTimeInterval) maxRetryInterval
readnonatomicassign

Maximum interval in seconds between two consecutive retries. Internal-only property used for GTMSessionFetcher transport retry policy.

Definition at line 127 of file GRPCCallOptions.h.

◆ minRetryInterval

- (NSTimeInterval) minRetryInterval
readnonatomicassign

Minimum interval in seconds between two consecutive retries. Internal-only property used for GTMSessionFetcher transport retry policy.

Definition at line 133 of file GRPCCallOptions.h.

◆ oauth2AccessToken

- (NSString*) oauth2AccessToken
readnonatomiccopy

The OAuth2 access token string. The string is prefixed with "Bearer " then used as value of the request's "authorization" header field. This parameter should not be used simultaneously with authTokenProvider.

Definition at line 75 of file GRPCCallOptions.h.

◆ PEMCertificateChain

- (NSString*) PEMCertificateChain
readnonatomiccopy

PEM format certificate chain for client authentication, if required by the server.

Definition at line 177 of file GRPCCallOptions.h.

◆ PEMPrivateKey

- (NSString*) PEMPrivateKey
readnonatomiccopy

PEM format private key for client authentication, if required by the server.

Definition at line 172 of file GRPCCallOptions.h.

◆ PEMRootCertificates

- (NSString*) PEMRootCertificates
readnonatomiccopy

PEM format root certifications that is trusted. If set to nil, gRPC uses a list of default root certificates.

Definition at line 167 of file GRPCCallOptions.h.

◆ responseSizeLimit

- (NSUInteger) responseSizeLimit
readnonatomicassign

The size limit for the response received from server. If it is exceeded, an error with status code GRPCErrorCodeResourceExhausted is returned.

Definition at line 108 of file GRPCCallOptions.h.

◆ retryEnabled

- (BOOL) retryEnabled
readnonatomicassign

Enable/Disable gRPC call's retry feature. The default is enabled. For details of this feature refer to https://github.com/grpc/proposal/blob/master/A6-client-retries.md

Definition at line 121 of file GRPCCallOptions.h.

◆ retryFactor

- (double) retryFactor
readatomicassign

Multiplier used to increase the interval between retries. Internal-only property used for GTMSessionFetcher transport retry policy.

Definition at line 139 of file GRPCCallOptions.h.

◆ serverAuthority

- (NSString*) serverAuthority
readnonatomiccopy

The authority for the RPC. If nil, the default authority will be used.

Note: This property does not have effect on Cronet transport and will be ignored. Note: This property cannot be used to validate a self-signed server certificate. It control the :authority header field of the call and performs an extra check that server's certificate matches the :authority header.

Definition at line 43 of file GRPCCallOptions.h.

◆ timeout

- (NSTimeInterval) timeout
readnonatomicassign

The timeout for the RPC call in seconds. If set to 0, the call will not timeout. If set to positive, the gRPC call returns with status GRPCErrorCodeDeadlineExceeded if it is not completed within timeout seconds. A negative value is not allowed.

Definition at line 50 of file GRPCCallOptions.h.

◆ transport

- (GRPCTransportID) transport
readnonatomicassign

The transport to be used for this call. Users may choose a native transport identifier defined in GRPCTransport or provided by a non-native transport implementation. If the option is left to be NULL, gRPC will use its default transport.

This is currently an experimental option.

Definition at line 195 of file GRPCCallOptions.h.

◆ transportType

- (GRPCTransportType) transportType
readnonatomicassign

Deprecated: this option is deprecated. Please use the property transport instead.

Select the transport type to be used for this call.

Definition at line 185 of file GRPCCallOptions.h.

◆ userAgentPrefix

- (NSString*) userAgentPrefix
readnonatomiccopy

Custom string that is prefixed to a request's user-agent header field before gRPC's internal user-agent string.

Definition at line 96 of file GRPCCallOptions.h.

◆ userAgentSuffix

- (NSString*) userAgentSuffix
readnonatomiccopy

Custom string that is suffixed to a request's user-agent header field after gRPC's internal user-agent string.

Definition at line 102 of file GRPCCallOptions.h.


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


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