GRPC Objective-C  1.71.0
Properties
GRPCMutableCallOptions Class Reference

Mutable user configurable options for a gRPC call. More...

#import <GRPCCallOptions.h>

Properties

NSString * serverAuthority
 The authority for the RPC. More...
 
NSTimeInterval timeout
 The timeout for the RPC call in seconds. More...
 
BOOL flowControlEnabled
 Enable flow control of a gRPC call. More...
 
NSArray< id< GRPCInterceptorFactory > > * interceptorFactories
 An array of interceptor factories. More...
 
NSString * oauth2AccessToken
 The OAuth2 access token string. More...
 
id< GRPCAuthorizationProtocolauthTokenProvider
 The interface to get the OAuth2 access token string. More...
 
GRPCMetadataDictionaryinitialMetadata
 Initial metadata key-value pairs that should be included in the request. More...
 
NSString * userAgentPrefix
 Custom string that is prefixed to a request's user-agent header field before gRPC's internal user-agent string. More...
 
NSString * userAgentSuffix
 Custom string that is suffixed to a request's user-agent header field after gRPC's internal user-agent string. More...
 
NSUInteger responseSizeLimit
 The size limit for the response received from server. More...
 
GRPCCompressionAlgorithm compressionAlgorithm
 The compression algorithm to be used by the gRPC call. More...
 
BOOL retryEnabled
 Enable/Disable gRPC call's retry feature. More...
 
NSTimeInterval maxRetryInterval
 Maximum interval in seconds between two consecutive retries. More...
 
NSTimeInterval minRetryInterval
 Minimum interval in seconds between two consecutive retries. More...
 
double retryFactor
 Multiplier used to increase the interval between retries. More...
 
NSTimeInterval keepaliveInterval
 
NSTimeInterval keepaliveTimeout
 
NSTimeInterval connectMinTimeout
 
NSTimeInterval connectInitialBackoff
 
NSTimeInterval connectMaxBackoff
 
GRPCMetadataDictionaryadditionalChannelArgs
 Specify channel args to be used for this call. More...
 
NSString * PEMRootCertificates
 PEM format root certifications that is trusted. More...
 
NSString * PEMPrivateKey
 PEM format private key for client authentication, if required by the server. More...
 
NSString * PEMCertificateChain
 PEM format certificate chain for client authentication, if required by the server. More...
 
GRPCTransportType transportType
 Deprecated: this option is deprecated. More...
 
GRPCTransportID transport
 The transport to be used for this call. More...
 
NSString * hostNameOverride
 Override the hostname during the TLS hostname validation process. More...
 
NSString * channelPoolDomain
 A string that specify the domain where channel is being cached. More...
 
NSUInteger channelID
 Channel id allows a call to force creating a new channel (connection) rather than using a cached channel. More...
 
- Properties inherited from GRPCCallOptions
NSString * serverAuthority
 The authority for the RPC. More...
 
NSTimeInterval timeout
 The timeout for the RPC call in seconds. More...
 
BOOL flowControlEnabled
 Enable flow control of a gRPC call. More...
 
NSArray< id< GRPCInterceptorFactory > > * interceptorFactories
 An array of interceptor factories. More...
 
NSString * oauth2AccessToken
 The OAuth2 access token string. More...
 
id< GRPCAuthorizationProtocolauthTokenProvider
 The interface to get the OAuth2 access token string. More...
 
GRPCMetadataDictionaryinitialMetadata
 Initial metadata key-value pairs that should be included in the request. More...
 
NSString * userAgentPrefix
 Custom string that is prefixed to a request's user-agent header field before gRPC's internal user-agent string. More...
 
NSString * userAgentSuffix
 Custom string that is suffixed to a request's user-agent header field after gRPC's internal user-agent string. More...
 
NSUInteger responseSizeLimit
 The size limit for the response received from server. More...
 
GRPCCompressionAlgorithm compressionAlgorithm
 The compression algorithm to be used by the gRPC call. More...
 
BOOL retryEnabled
 Enable/Disable gRPC call's retry feature. More...
 
NSTimeInterval maxRetryInterval
 Maximum interval in seconds between two consecutive retries. More...
 
NSTimeInterval minRetryInterval
 Minimum interval in seconds between two consecutive retries. More...
 
double retryFactor
 Multiplier used to increase the interval between retries. More...
 
NSTimeInterval keepaliveInterval
 
NSTimeInterval keepaliveTimeout
 
NSTimeInterval connectMinTimeout
 
NSTimeInterval connectInitialBackoff
 
NSTimeInterval connectMaxBackoff
 
GRPCMetadataDictionaryadditionalChannelArgs
 Specify channel args to be used for this call. More...
 
NSString * PEMRootCertificates
 PEM format root certifications that is trusted. More...
 
NSString * PEMPrivateKey
 PEM format private key for client authentication, if required by the server. More...
 
NSString * PEMCertificateChain
 PEM format certificate chain for client authentication, if required by the server. More...
 
GRPCTransportType transportType
 Deprecated: this option is deprecated. More...
 
GRPCTransportID transport
 The transport to be used for this call. More...
 
NSString * hostNameOverride
 Override the hostname during the TLS hostname validation process. More...
 
NSString * channelPoolDomain
 A string that specify the domain where channel is being cached. More...
 
NSUInteger channelID
 Channel id allows control of channel caching within a channelPoolDomain. More...
 
NSUInteger channelOptionsHash
 Hash for channel options. More...
 

Additional Inherited Members

- Instance Methods inherited from GRPCCallOptions
(BOOL) - hasChannelOptionsEqualTo:
 Return if the channel options are equal to another object. More...
 

Detailed Description

Mutable user configurable options for a gRPC call.

Caller can obtain an immutable copy of type GRPCCallOptions by calling [option copy]

Property Documentation

◆ additionalChannelArgs

- (GRPCMetadataDictionary*) additionalChannelArgs
readwritenonatomiccopy

Specify channel args to be used for this call.

For a list of channel args available, see grpc/grpc_types.h

◆ authTokenProvider

- (id<GRPCAuthorizationProtocol>) authTokenProvider
readwritenonatomicassign

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.

◆ channelID

- (NSUInteger) channelID
readwritenonatomicassign

Channel id allows a call to force creating a new channel (connection) rather than using a cached channel.

Calls using distinct channelID's will not get cached to the same channel.

◆ channelPoolDomain

- (NSString*) channelPoolDomain
readwritenonatomiccopy

A string that specify the domain where channel is being cached.

Channels with different domains will not get cached to the same channel. For example, a gRPC example app may use the channel pool domain 'io.grpc.example' so that its calls do not reuse the channel created by other modules in the same process.

◆ compressionAlgorithm

- (GRPCCompressionAlgorithm) compressionAlgorithm
readwritenonatomicassign

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

◆ connectInitialBackoff

- (NSTimeInterval) connectInitialBackoff
readwritenonatomicassign

◆ connectMaxBackoff

- (NSTimeInterval) connectMaxBackoff
readwritenonatomicassign

◆ connectMinTimeout

- (NSTimeInterval) connectMinTimeout
readwritenonatomicassign

◆ flowControlEnabled

- (BOOL) flowControlEnabled
readwritenonatomicassign

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 can issue a didReceiveMessage callback.

If writeData: method is called more than once before issuance of a didWriteData callback, gRPC will continue to queue the message and write them to gRPC core in order. However, the user assumes their own responsibility of flow control by keeping tracking of the pending writes in the call.

◆ hostNameOverride

- (NSString*) hostNameOverride
readwritenonatomiccopy

Override the hostname during the TLS hostname validation process.

◆ initialMetadata

- (GRPCMetadataDictionary*) initialMetadata
readwritenonatomiccopy

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.

◆ interceptorFactories

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

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.

◆ keepaliveInterval

- (NSTimeInterval) keepaliveInterval
readwritenonatomicassign

◆ keepaliveTimeout

- (NSTimeInterval) keepaliveTimeout
readwritenonatomicassign

◆ maxRetryInterval

- (NSTimeInterval) maxRetryInterval
readwritenonatomicassign

Maximum interval in seconds between two consecutive retries.

Pass 0 to use default. Internal-only property used for GTMSessionFetcher transport retry policy.

◆ minRetryInterval

- (NSTimeInterval) minRetryInterval
readwritenonatomicassign

Minimum interval in seconds between two consecutive retries.

Pass 0 to use default. Internal-only property used for GTMSessionFetcher transport retry policy.

◆ oauth2AccessToken

- (NSString*) oauth2AccessToken
readwritenonatomiccopy

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.

◆ PEMCertificateChain

- (NSString*) PEMCertificateChain
readwritenonatomiccopy

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

◆ PEMPrivateKey

- (NSString*) PEMPrivateKey
readwritenonatomiccopy

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

◆ PEMRootCertificates

- (NSString*) PEMRootCertificates
readwritenonatomiccopy

PEM format root certifications that is trusted.

If set to nil, gRPC uses a list of default root certificates.

◆ responseSizeLimit

- (NSUInteger) responseSizeLimit
readwritenonatomicassign

The size limit for the response received from server.

If it is exceeded, an error with status code GRPCErrorCodeResourceExhausted is returned.

◆ retryEnabled

- (BOOL) retryEnabled
readwritenonatomicassign

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

◆ retryFactor

- (double) retryFactor
readwritenonatomicassign

Multiplier used to increase the interval between retries.

Pass 0 to use default. Internal-only property used for GTMSessionFetcher transport retry policy.

◆ serverAuthority

- (NSString*) serverAuthority
readwritenonatomiccopy

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.

◆ timeout

- (NSTimeInterval) timeout
readwritenonatomicassign

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. Negative value is invalid; setting the parameter to negative value will reset the parameter to 0.

◆ transport

- (GRPCTransportID) transport
readwritenonatomicassign

The transport to be used for this call.

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

An interceptor must not change the value of this option.

◆ transportType

- (GRPCTransportType) transportType
readwritenonatomicassign

Deprecated: this option is deprecated.

Please use the property transport instead.

Select the transport type to be used for this call.

◆ userAgentPrefix

- (NSString*) userAgentPrefix
readwritenonatomiccopy

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

◆ userAgentSuffix

- (NSString*) userAgentSuffix
readwritenonatomiccopy

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


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