Interface IClientServiceRequest
A client service request which supports both sync and async execution to get the stream.
Namespace: Google.Apis.Requests
Assembly: Google.Apis.dll
Syntax
public interface IClientServiceRequest
Properties
HttpMethod
Gets the HTTP method of this request.
Declaration
string HttpMethod { get; }
Property Value
Type | Description |
---|---|
System.String |
MethodName
Gets the name of the method to which this request belongs.
Declaration
string MethodName { get; }
Property Value
Type | Description |
---|---|
System.String |
RequestParameters
Gets the parameters information for this specific request.
Declaration
IDictionary<string, IParameter> RequestParameters { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IDictionary<System.String, IParameter> |
RestPath
Gets the rest path of this request.
Declaration
string RestPath { get; }
Property Value
Type | Description |
---|---|
System.String |
Service
Gets the service which is related to this request.
Declaration
IClientService Service { get; }
Property Value
Type | Description |
---|---|
IClientService |
Methods
CreateRequest(Nullable<Boolean>)
Creates a HTTP request message with all path and query parameters, ETag, etc.
Declaration
HttpRequestMessage CreateRequest(bool? overrideGZipEnabled = null)
Parameters
Type | Name | Description |
---|---|---|
System.Nullable<System.Boolean> | overrideGZipEnabled | If |
Returns
Type | Description |
---|---|
System.Net.Http.HttpRequestMessage |
ExecuteAsStream()
Executes the request and returns the result stream.
Declaration
Stream ExecuteAsStream()
Returns
Type | Description |
---|---|
System.IO.Stream |
ExecuteAsStreamAsync()
Executes the request asynchronously and returns the result stream.
Declaration
Task<Stream> ExecuteAsStreamAsync()
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.IO.Stream> |
ExecuteAsStreamAsync(CancellationToken)
Executes the request asynchronously and returns the result stream.
Declaration
Task<Stream> ExecuteAsStreamAsync(CancellationToken cancellationToken)
Parameters
Type | Name | Description |
---|---|---|
System.Threading.CancellationToken | cancellationToken | A cancellation token to cancel operation. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.IO.Stream> |