Reference documentation and code samples for the Google API Core Client class CallOptions.
The CallOptions class provides typing to the associative array of options passed to transport RPC methods. See Google\ApiCore\Transport\TransportInterface::startUnaryCall(), Google\ApiCore\Transport\TransportInterface::startBidiStreamingCall(), Google\ApiCore\Transport\TransportInterface::startClientStreamingCall(), and Google\ApiCore\Transport\TransportInterface::startServerStreamingCall().
Namespace
Google \ ApiCore \ OptionsMethods
__construct
Parameters | |
---|---|
Name | Description |
options |
array
Call options |
↳ array |
array<>
|
↳ timeoutMillis |
int
The timeout in milliseconds for the call. |
↳ transportOptions |
array
Transport-specific call options. See Google\ApiCore\Options\CallOptions::setTransportOptions. |
↳ retrySettings |
RetrySettings|array
A retry settings override for the call. If $retrySettings is an array, the settings will be merged with the method's default retry settings. If $retrySettings is a RetrySettings object, that object will be used instead of the method defaults. |
setHeaders
Parameter | |
---|---|
Name | Description |
headers |
array
|
setTimeoutMillis
Parameter | |
---|---|
Name | Description |
timeoutMillis |
int|null
|
setTransportOptions
Parameters | |
---|---|
Name | Description |
transportOptions |
array
Transport-specific call-time options. |
↳ grpcOptions |
array
Key-value pairs for gRPC-specific options passed as the |
↳ grpcFallbackOptions |
array
Key-value pairs for gRPC fallback specific options passed as the |
↳ restOptions |
array
Key-value pairs for REST-specific options passed as the |
setTransportSpecificOptions
Parameter | |
---|---|
Name | Description |
transportSpecificOptions |
array
|
setRetrySettings
Parameter | |
---|---|
Name | Description |
retrySettings |
Google\ApiCore\RetrySettings|array|null
|