Google Cloud Dialogflow v2 API - Class AnswerRecordsClient (4.24.0)

public abstract class AnswerRecordsClient

Reference documentation and code samples for the Google Cloud Dialogflow v2 API class AnswerRecordsClient.

AnswerRecords client wrapper, for convenient use.

Inheritance

object > AnswerRecordsClient

Derived Types

Namespace

Google.Cloud.Dialogflow.V2

Assembly

Google.Cloud.Dialogflow.V2.dll

Remarks

Service for managing [AnswerRecords][google.cloud.dialogflow.v2.AnswerRecord].

Properties

DefaultEndpoint

public static string DefaultEndpoint { get; }

The default endpoint for the AnswerRecords service, which is a host of "dialogflow.googleapis.com" and a port of 443.

Property Value
Type Description
string

DefaultScopes

public static IReadOnlyList<string> DefaultScopes { get; }

The default AnswerRecords scopes.

Property Value
Type Description
IReadOnlyListstring
Remarks

GrpcClient

public virtual AnswerRecords.AnswerRecordsClient GrpcClient { get; }

The underlying gRPC AnswerRecords client

Property Value
Type Description
AnswerRecordsAnswerRecordsClient

LocationsClient

public virtual LocationsClient LocationsClient { get; }

The LocationsClient associated with this client.

Property Value
Type Description
LocationsClient

ServiceMetadata

public static ServiceMetadata ServiceMetadata { get; }

The service metadata associated with this client type.

Property Value
Type Description
ServiceMetadata

Methods

Create()

public static AnswerRecordsClient Create()

Synchronously creates a AnswerRecordsClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use AnswerRecordsClientBuilder.

Returns
Type Description
AnswerRecordsClient

The created AnswerRecordsClient.

CreateAsync(CancellationToken)

public static Task<AnswerRecordsClient> CreateAsync(CancellationToken cancellationToken = default)

Asynchronously creates a AnswerRecordsClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use AnswerRecordsClientBuilder.

Parameter
Name Description
cancellationToken CancellationToken

The CancellationToken to use while creating the client.

Returns
Type Description
TaskAnswerRecordsClient

The task representing the created AnswerRecordsClient.

ListAnswerRecords(LocationName, string, int?, CallSettings)

public virtual PagedEnumerable<ListAnswerRecordsResponse, AnswerRecord> ListAnswerRecords(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the list of all answer records in the specified project in reverse chronological order.

Parameters
Name Description
parent LocationName

Required. The project to list all answer records for in reverse chronological order. Format: projects/<Project ID>/locations/<Location ID>.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAnswerRecordsResponseAnswerRecord

A pageable sequence of AnswerRecord resources.

Example
// Create client
AnswerRecordsClient answerRecordsClient = AnswerRecordsClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListAnswerRecordsResponse, AnswerRecord> response = answerRecordsClient.ListAnswerRecords(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (AnswerRecord item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAnswerRecordsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AnswerRecord item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AnswerRecord> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AnswerRecord item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAnswerRecords(ProjectName, string, int?, CallSettings)

public virtual PagedEnumerable<ListAnswerRecordsResponse, AnswerRecord> ListAnswerRecords(ProjectName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the list of all answer records in the specified project in reverse chronological order.

Parameters
Name Description
parent ProjectName

Required. The project to list all answer records for in reverse chronological order. Format: projects/<Project ID>/locations/<Location ID>.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAnswerRecordsResponseAnswerRecord

A pageable sequence of AnswerRecord resources.

Example
// Create client
AnswerRecordsClient answerRecordsClient = AnswerRecordsClient.Create();
// Initialize request argument(s)
ProjectName parent = ProjectName.FromProject("[PROJECT]");
// Make the request
PagedEnumerable<ListAnswerRecordsResponse, AnswerRecord> response = answerRecordsClient.ListAnswerRecords(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (AnswerRecord item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAnswerRecordsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AnswerRecord item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AnswerRecord> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AnswerRecord item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAnswerRecords(ListAnswerRecordsRequest, CallSettings)

public virtual PagedEnumerable<ListAnswerRecordsResponse, AnswerRecord> ListAnswerRecords(ListAnswerRecordsRequest request, CallSettings callSettings = null)

Returns the list of all answer records in the specified project in reverse chronological order.

Parameters
Name Description
request ListAnswerRecordsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAnswerRecordsResponseAnswerRecord

A pageable sequence of AnswerRecord resources.

Example
// Create client
AnswerRecordsClient answerRecordsClient = AnswerRecordsClient.Create();
// Initialize request argument(s)
ListAnswerRecordsRequest request = new ListAnswerRecordsRequest
{
    ParentAsProjectName = ProjectName.FromProject("[PROJECT]"),
};
// Make the request
PagedEnumerable<ListAnswerRecordsResponse, AnswerRecord> response = answerRecordsClient.ListAnswerRecords(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (AnswerRecord item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAnswerRecordsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AnswerRecord item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AnswerRecord> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AnswerRecord item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAnswerRecords(string, string, int?, CallSettings)

public virtual PagedEnumerable<ListAnswerRecordsResponse, AnswerRecord> ListAnswerRecords(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the list of all answer records in the specified project in reverse chronological order.

Parameters
Name Description
parent string

Required. The project to list all answer records for in reverse chronological order. Format: projects/<Project ID>/locations/<Location ID>.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListAnswerRecordsResponseAnswerRecord

A pageable sequence of AnswerRecord resources.

Example
// Create client
AnswerRecordsClient answerRecordsClient = AnswerRecordsClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]";
// Make the request
PagedEnumerable<ListAnswerRecordsResponse, AnswerRecord> response = answerRecordsClient.ListAnswerRecords(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (AnswerRecord item in response)
{
    // Do something with each item
    Console.WriteLine(item);
}

// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListAnswerRecordsResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AnswerRecord item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
}

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AnswerRecord> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AnswerRecord item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAnswerRecordsAsync(LocationName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListAnswerRecordsResponse, AnswerRecord> ListAnswerRecordsAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the list of all answer records in the specified project in reverse chronological order.

Parameters
Name Description
parent LocationName

Required. The project to list all answer records for in reverse chronological order. Format: projects/<Project ID>/locations/<Location ID>.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAnswerRecordsResponseAnswerRecord

A pageable asynchronous sequence of AnswerRecord resources.

Example
// Create client
AnswerRecordsClient answerRecordsClient = await AnswerRecordsClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListAnswerRecordsResponse, AnswerRecord> response = answerRecordsClient.ListAnswerRecordsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((AnswerRecord item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListAnswerRecordsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AnswerRecord item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
});

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AnswerRecord> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AnswerRecord item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAnswerRecordsAsync(ProjectName, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListAnswerRecordsResponse, AnswerRecord> ListAnswerRecordsAsync(ProjectName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the list of all answer records in the specified project in reverse chronological order.

Parameters
Name Description
parent ProjectName

Required. The project to list all answer records for in reverse chronological order. Format: projects/<Project ID>/locations/<Location ID>.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAnswerRecordsResponseAnswerRecord

A pageable asynchronous sequence of AnswerRecord resources.

Example
// Create client
AnswerRecordsClient answerRecordsClient = await AnswerRecordsClient.CreateAsync();
// Initialize request argument(s)
ProjectName parent = ProjectName.FromProject("[PROJECT]");
// Make the request
PagedAsyncEnumerable<ListAnswerRecordsResponse, AnswerRecord> response = answerRecordsClient.ListAnswerRecordsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((AnswerRecord item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListAnswerRecordsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AnswerRecord item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
});

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AnswerRecord> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AnswerRecord item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAnswerRecordsAsync(ListAnswerRecordsRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListAnswerRecordsResponse, AnswerRecord> ListAnswerRecordsAsync(ListAnswerRecordsRequest request, CallSettings callSettings = null)

Returns the list of all answer records in the specified project in reverse chronological order.

Parameters
Name Description
request ListAnswerRecordsRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAnswerRecordsResponseAnswerRecord

A pageable asynchronous sequence of AnswerRecord resources.

Example
// Create client
AnswerRecordsClient answerRecordsClient = await AnswerRecordsClient.CreateAsync();
// Initialize request argument(s)
ListAnswerRecordsRequest request = new ListAnswerRecordsRequest
{
    ParentAsProjectName = ProjectName.FromProject("[PROJECT]"),
};
// Make the request
PagedAsyncEnumerable<ListAnswerRecordsResponse, AnswerRecord> response = answerRecordsClient.ListAnswerRecordsAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((AnswerRecord item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListAnswerRecordsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AnswerRecord item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
});

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AnswerRecord> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AnswerRecord item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ListAnswerRecordsAsync(string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListAnswerRecordsResponse, AnswerRecord> ListAnswerRecordsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Returns the list of all answer records in the specified project in reverse chronological order.

Parameters
Name Description
parent string

Required. The project to list all answer records for in reverse chronological order. Format: projects/<Project ID>/locations/<Location ID>.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListAnswerRecordsResponseAnswerRecord

A pageable asynchronous sequence of AnswerRecord resources.

Example
// Create client
AnswerRecordsClient answerRecordsClient = await AnswerRecordsClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]";
// Make the request
PagedAsyncEnumerable<ListAnswerRecordsResponse, AnswerRecord> response = answerRecordsClient.ListAnswerRecordsAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((AnswerRecord item) =>
{
    // Do something with each item
    Console.WriteLine(item);
});

// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListAnswerRecordsResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (AnswerRecord item in page)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
});

// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<AnswerRecord> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (AnswerRecord item in singlePage)
{
    // Do something with each item
    Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;

ShutdownDefaultChannelsAsync()

public static Task ShutdownDefaultChannelsAsync()

Shuts down any channels automatically created by Create() and CreateAsync(CancellationToken). Channels which weren't automatically created are not affected.

Returns
Type Description
Task

A task representing the asynchronous shutdown operation.

Remarks

After calling this method, further calls to Create() and CreateAsync(CancellationToken) will create new channels, which could in turn be shut down by another call to this method.

UpdateAnswerRecord(AnswerRecord, FieldMask, CallSettings)

public virtual AnswerRecord UpdateAnswerRecord(AnswerRecord answerRecord, FieldMask updateMask, CallSettings callSettings = null)

Updates the specified answer record.

Parameters
Name Description
answerRecord AnswerRecord

Required. Answer record to update.

updateMask FieldMask

Required. The mask to control which fields get updated.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
AnswerRecord

The RPC response.

Example
// Create client
AnswerRecordsClient answerRecordsClient = AnswerRecordsClient.Create();
// Initialize request argument(s)
AnswerRecord answerRecord = new AnswerRecord();
FieldMask updateMask = new FieldMask();
// Make the request
AnswerRecord response = answerRecordsClient.UpdateAnswerRecord(answerRecord, updateMask);

UpdateAnswerRecord(UpdateAnswerRecordRequest, CallSettings)

public virtual AnswerRecord UpdateAnswerRecord(UpdateAnswerRecordRequest request, CallSettings callSettings = null)

Updates the specified answer record.

Parameters
Name Description
request UpdateAnswerRecordRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
AnswerRecord

The RPC response.

Example
// Create client
AnswerRecordsClient answerRecordsClient = AnswerRecordsClient.Create();
// Initialize request argument(s)
UpdateAnswerRecordRequest request = new UpdateAnswerRecordRequest
{
    AnswerRecord = new AnswerRecord(),
    UpdateMask = new FieldMask(),
};
// Make the request
AnswerRecord response = answerRecordsClient.UpdateAnswerRecord(request);

UpdateAnswerRecordAsync(AnswerRecord, FieldMask, CallSettings)

public virtual Task<AnswerRecord> UpdateAnswerRecordAsync(AnswerRecord answerRecord, FieldMask updateMask, CallSettings callSettings = null)

Updates the specified answer record.

Parameters
Name Description
answerRecord AnswerRecord

Required. Answer record to update.

updateMask FieldMask

Required. The mask to control which fields get updated.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskAnswerRecord

A Task containing the RPC response.

Example
// Create client
AnswerRecordsClient answerRecordsClient = await AnswerRecordsClient.CreateAsync();
// Initialize request argument(s)
AnswerRecord answerRecord = new AnswerRecord();
FieldMask updateMask = new FieldMask();
// Make the request
AnswerRecord response = await answerRecordsClient.UpdateAnswerRecordAsync(answerRecord, updateMask);

UpdateAnswerRecordAsync(AnswerRecord, FieldMask, CancellationToken)

public virtual Task<AnswerRecord> UpdateAnswerRecordAsync(AnswerRecord answerRecord, FieldMask updateMask, CancellationToken cancellationToken)

Updates the specified answer record.

Parameters
Name Description
answerRecord AnswerRecord

Required. Answer record to update.

updateMask FieldMask

Required. The mask to control which fields get updated.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskAnswerRecord

A Task containing the RPC response.

Example
// Create client
AnswerRecordsClient answerRecordsClient = await AnswerRecordsClient.CreateAsync();
// Initialize request argument(s)
AnswerRecord answerRecord = new AnswerRecord();
FieldMask updateMask = new FieldMask();
// Make the request
AnswerRecord response = await answerRecordsClient.UpdateAnswerRecordAsync(answerRecord, updateMask);

UpdateAnswerRecordAsync(UpdateAnswerRecordRequest, CallSettings)

public virtual Task<AnswerRecord> UpdateAnswerRecordAsync(UpdateAnswerRecordRequest request, CallSettings callSettings = null)

Updates the specified answer record.

Parameters
Name Description
request UpdateAnswerRecordRequest

The request object containing all of the parameters for the API call.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskAnswerRecord

A Task containing the RPC response.

Example
// Create client
AnswerRecordsClient answerRecordsClient = await AnswerRecordsClient.CreateAsync();
// Initialize request argument(s)
UpdateAnswerRecordRequest request = new UpdateAnswerRecordRequest
{
    AnswerRecord = new AnswerRecord(),
    UpdateMask = new FieldMask(),
};
// Make the request
AnswerRecord response = await answerRecordsClient.UpdateAnswerRecordAsync(request);

UpdateAnswerRecordAsync(UpdateAnswerRecordRequest, CancellationToken)

public virtual Task<AnswerRecord> UpdateAnswerRecordAsync(UpdateAnswerRecordRequest request, CancellationToken cancellationToken)

Updates the specified answer record.

Parameters
Name Description
request UpdateAnswerRecordRequest

The request object containing all of the parameters for the API call.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskAnswerRecord

A Task containing the RPC response.

Example
// Create client
AnswerRecordsClient answerRecordsClient = await AnswerRecordsClient.CreateAsync();
// Initialize request argument(s)
UpdateAnswerRecordRequest request = new UpdateAnswerRecordRequest
{
    AnswerRecord = new AnswerRecord(),
    UpdateMask = new FieldMask(),
};
// Make the request
AnswerRecord response = await answerRecordsClient.UpdateAnswerRecordAsync(request);