public abstract class ReferenceListServiceClient
Reference documentation and code samples for the Chronicle v1 API class ReferenceListServiceClient.
ReferenceListService client wrapper, for convenient use.
Derived Types
Namespace
Google.Cloud.Chronicle.V1Assembly
Google.Cloud.Chronicle.V1.dll
Remarks
ReferenceListService provides an interface for managing reference lists.
Properties
DefaultEndpoint
public static string DefaultEndpoint { get; }
The default endpoint for the ReferenceListService service, which is a host of "chronicle.googleapis.com" and a port of 443.
Property Value | |
---|---|
Type | Description |
string |
DefaultScopes
public static IReadOnlyList<string> DefaultScopes { get; }
The default ReferenceListService scopes.
Property Value | |
---|---|
Type | Description |
IReadOnlyListstring |
The default ReferenceListService scopes are:
GrpcClient
public virtual ReferenceListService.ReferenceListServiceClient GrpcClient { get; }
The underlying gRPC ReferenceListService client
Property Value | |
---|---|
Type | Description |
ReferenceListServiceReferenceListServiceClient |
ServiceMetadata
public static ServiceMetadata ServiceMetadata { get; }
The service metadata associated with this client type.
Property Value | |
---|---|
Type | Description |
ServiceMetadata |
Methods
Create()
public static ReferenceListServiceClient Create()
Synchronously creates a ReferenceListServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use ReferenceListServiceClientBuilder.
Returns | |
---|---|
Type | Description |
ReferenceListServiceClient |
The created ReferenceListServiceClient. |
CreateAsync(CancellationToken)
public static Task<ReferenceListServiceClient> CreateAsync(CancellationToken cancellationToken = default)
Asynchronously creates a ReferenceListServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use ReferenceListServiceClientBuilder.
Parameter | |
---|---|
Name | Description |
cancellationToken |
CancellationToken The CancellationToken to use while creating the client. |
Returns | |
---|---|
Type | Description |
TaskReferenceListServiceClient |
The task representing the created ReferenceListServiceClient. |
CreateReferenceList(CreateReferenceListRequest, CallSettings)
public virtual ReferenceList CreateReferenceList(CreateReferenceListRequest request, CallSettings callSettings = null)
Creates a new reference list.
Parameters | |
---|---|
Name | Description |
request |
CreateReferenceListRequest 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 |
ReferenceList |
The RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
CreateReferenceListRequest request = new CreateReferenceListRequest
{
ParentAsInstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
ReferenceList = new ReferenceList(),
ReferenceListId = "",
};
// Make the request
ReferenceList response = referenceListServiceClient.CreateReferenceList(request);
CreateReferenceList(InstanceName, ReferenceList, string, CallSettings)
public virtual ReferenceList CreateReferenceList(InstanceName parent, ReferenceList referenceList, string referenceListId, CallSettings callSettings = null)
Creates a new reference list.
Parameters | |
---|---|
Name | Description |
parent |
InstanceName Required. The parent resource where this reference list will be created.
Format: |
referenceList |
ReferenceList Required. The reference list to create. |
referenceListId |
string Required. The ID to use for the reference list. This is also the display name for the reference list. It must satisfy the following requirements:
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
ReferenceList |
The RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
InstanceName parent = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
ReferenceList referenceList = new ReferenceList();
string referenceListId = "";
// Make the request
ReferenceList response = referenceListServiceClient.CreateReferenceList(parent, referenceList, referenceListId);
CreateReferenceList(string, ReferenceList, string, CallSettings)
public virtual ReferenceList CreateReferenceList(string parent, ReferenceList referenceList, string referenceListId, CallSettings callSettings = null)
Creates a new reference list.
Parameters | |
---|---|
Name | Description |
parent |
string Required. The parent resource where this reference list will be created.
Format: |
referenceList |
ReferenceList Required. The reference list to create. |
referenceListId |
string Required. The ID to use for the reference list. This is also the display name for the reference list. It must satisfy the following requirements:
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
ReferenceList |
The RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
ReferenceList referenceList = new ReferenceList();
string referenceListId = "";
// Make the request
ReferenceList response = referenceListServiceClient.CreateReferenceList(parent, referenceList, referenceListId);
CreateReferenceListAsync(CreateReferenceListRequest, CallSettings)
public virtual Task<ReferenceList> CreateReferenceListAsync(CreateReferenceListRequest request, CallSettings callSettings = null)
Creates a new reference list.
Parameters | |
---|---|
Name | Description |
request |
CreateReferenceListRequest 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 |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
CreateReferenceListRequest request = new CreateReferenceListRequest
{
ParentAsInstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
ReferenceList = new ReferenceList(),
ReferenceListId = "",
};
// Make the request
ReferenceList response = await referenceListServiceClient.CreateReferenceListAsync(request);
CreateReferenceListAsync(CreateReferenceListRequest, CancellationToken)
public virtual Task<ReferenceList> CreateReferenceListAsync(CreateReferenceListRequest request, CancellationToken cancellationToken)
Creates a new reference list.
Parameters | |
---|---|
Name | Description |
request |
CreateReferenceListRequest The request object containing all of the parameters for the API call. |
cancellationToken |
CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
CreateReferenceListRequest request = new CreateReferenceListRequest
{
ParentAsInstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
ReferenceList = new ReferenceList(),
ReferenceListId = "",
};
// Make the request
ReferenceList response = await referenceListServiceClient.CreateReferenceListAsync(request);
CreateReferenceListAsync(InstanceName, ReferenceList, string, CallSettings)
public virtual Task<ReferenceList> CreateReferenceListAsync(InstanceName parent, ReferenceList referenceList, string referenceListId, CallSettings callSettings = null)
Creates a new reference list.
Parameters | |
---|---|
Name | Description |
parent |
InstanceName Required. The parent resource where this reference list will be created.
Format: |
referenceList |
ReferenceList Required. The reference list to create. |
referenceListId |
string Required. The ID to use for the reference list. This is also the display name for the reference list. It must satisfy the following requirements:
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
InstanceName parent = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
ReferenceList referenceList = new ReferenceList();
string referenceListId = "";
// Make the request
ReferenceList response = await referenceListServiceClient.CreateReferenceListAsync(parent, referenceList, referenceListId);
CreateReferenceListAsync(InstanceName, ReferenceList, string, CancellationToken)
public virtual Task<ReferenceList> CreateReferenceListAsync(InstanceName parent, ReferenceList referenceList, string referenceListId, CancellationToken cancellationToken)
Creates a new reference list.
Parameters | |
---|---|
Name | Description |
parent |
InstanceName Required. The parent resource where this reference list will be created.
Format: |
referenceList |
ReferenceList Required. The reference list to create. |
referenceListId |
string Required. The ID to use for the reference list. This is also the display name for the reference list. It must satisfy the following requirements:
|
cancellationToken |
CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
InstanceName parent = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
ReferenceList referenceList = new ReferenceList();
string referenceListId = "";
// Make the request
ReferenceList response = await referenceListServiceClient.CreateReferenceListAsync(parent, referenceList, referenceListId);
CreateReferenceListAsync(string, ReferenceList, string, CallSettings)
public virtual Task<ReferenceList> CreateReferenceListAsync(string parent, ReferenceList referenceList, string referenceListId, CallSettings callSettings = null)
Creates a new reference list.
Parameters | |
---|---|
Name | Description |
parent |
string Required. The parent resource where this reference list will be created.
Format: |
referenceList |
ReferenceList Required. The reference list to create. |
referenceListId |
string Required. The ID to use for the reference list. This is also the display name for the reference list. It must satisfy the following requirements:
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
ReferenceList referenceList = new ReferenceList();
string referenceListId = "";
// Make the request
ReferenceList response = await referenceListServiceClient.CreateReferenceListAsync(parent, referenceList, referenceListId);
CreateReferenceListAsync(string, ReferenceList, string, CancellationToken)
public virtual Task<ReferenceList> CreateReferenceListAsync(string parent, ReferenceList referenceList, string referenceListId, CancellationToken cancellationToken)
Creates a new reference list.
Parameters | |
---|---|
Name | Description |
parent |
string Required. The parent resource where this reference list will be created.
Format: |
referenceList |
ReferenceList Required. The reference list to create. |
referenceListId |
string Required. The ID to use for the reference list. This is also the display name for the reference list. It must satisfy the following requirements:
|
cancellationToken |
CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
ReferenceList referenceList = new ReferenceList();
string referenceListId = "";
// Make the request
ReferenceList response = await referenceListServiceClient.CreateReferenceListAsync(parent, referenceList, referenceListId);
GetReferenceList(GetReferenceListRequest, CallSettings)
public virtual ReferenceList GetReferenceList(GetReferenceListRequest request, CallSettings callSettings = null)
Gets a single reference list.
Parameters | |
---|---|
Name | Description |
request |
GetReferenceListRequest 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 |
ReferenceList |
The RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
GetReferenceListRequest request = new GetReferenceListRequest
{
ReferenceListName = ReferenceListName.FromProjectLocationInstanceReferenceList("[PROJECT]", "[LOCATION]", "[INSTANCE]", "[REFERENCE_LIST]"),
View = ReferenceListView.Unspecified,
};
// Make the request
ReferenceList response = referenceListServiceClient.GetReferenceList(request);
GetReferenceList(ReferenceListName, CallSettings)
public virtual ReferenceList GetReferenceList(ReferenceListName name, CallSettings callSettings = null)
Gets a single reference list.
Parameters | |
---|---|
Name | Description |
name |
ReferenceListName Required. The resource name of the reference list to retrieve.
Format:
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
ReferenceList |
The RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
ReferenceListName name = ReferenceListName.FromProjectLocationInstanceReferenceList("[PROJECT]", "[LOCATION]", "[INSTANCE]", "[REFERENCE_LIST]");
// Make the request
ReferenceList response = referenceListServiceClient.GetReferenceList(name);
GetReferenceList(string, CallSettings)
public virtual ReferenceList GetReferenceList(string name, CallSettings callSettings = null)
Gets a single reference list.
Parameters | |
---|---|
Name | Description |
name |
string Required. The resource name of the reference list to retrieve.
Format:
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
ReferenceList |
The RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]/referenceLists/[REFERENCE_LIST]";
// Make the request
ReferenceList response = referenceListServiceClient.GetReferenceList(name);
GetReferenceListAsync(GetReferenceListRequest, CallSettings)
public virtual Task<ReferenceList> GetReferenceListAsync(GetReferenceListRequest request, CallSettings callSettings = null)
Gets a single reference list.
Parameters | |
---|---|
Name | Description |
request |
GetReferenceListRequest 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 |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
GetReferenceListRequest request = new GetReferenceListRequest
{
ReferenceListName = ReferenceListName.FromProjectLocationInstanceReferenceList("[PROJECT]", "[LOCATION]", "[INSTANCE]", "[REFERENCE_LIST]"),
View = ReferenceListView.Unspecified,
};
// Make the request
ReferenceList response = await referenceListServiceClient.GetReferenceListAsync(request);
GetReferenceListAsync(GetReferenceListRequest, CancellationToken)
public virtual Task<ReferenceList> GetReferenceListAsync(GetReferenceListRequest request, CancellationToken cancellationToken)
Gets a single reference list.
Parameters | |
---|---|
Name | Description |
request |
GetReferenceListRequest The request object containing all of the parameters for the API call. |
cancellationToken |
CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
GetReferenceListRequest request = new GetReferenceListRequest
{
ReferenceListName = ReferenceListName.FromProjectLocationInstanceReferenceList("[PROJECT]", "[LOCATION]", "[INSTANCE]", "[REFERENCE_LIST]"),
View = ReferenceListView.Unspecified,
};
// Make the request
ReferenceList response = await referenceListServiceClient.GetReferenceListAsync(request);
GetReferenceListAsync(ReferenceListName, CallSettings)
public virtual Task<ReferenceList> GetReferenceListAsync(ReferenceListName name, CallSettings callSettings = null)
Gets a single reference list.
Parameters | |
---|---|
Name | Description |
name |
ReferenceListName Required. The resource name of the reference list to retrieve.
Format:
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
ReferenceListName name = ReferenceListName.FromProjectLocationInstanceReferenceList("[PROJECT]", "[LOCATION]", "[INSTANCE]", "[REFERENCE_LIST]");
// Make the request
ReferenceList response = await referenceListServiceClient.GetReferenceListAsync(name);
GetReferenceListAsync(ReferenceListName, CancellationToken)
public virtual Task<ReferenceList> GetReferenceListAsync(ReferenceListName name, CancellationToken cancellationToken)
Gets a single reference list.
Parameters | |
---|---|
Name | Description |
name |
ReferenceListName Required. The resource name of the reference list to retrieve.
Format:
|
cancellationToken |
CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
ReferenceListName name = ReferenceListName.FromProjectLocationInstanceReferenceList("[PROJECT]", "[LOCATION]", "[INSTANCE]", "[REFERENCE_LIST]");
// Make the request
ReferenceList response = await referenceListServiceClient.GetReferenceListAsync(name);
GetReferenceListAsync(string, CallSettings)
public virtual Task<ReferenceList> GetReferenceListAsync(string name, CallSettings callSettings = null)
Gets a single reference list.
Parameters | |
---|---|
Name | Description |
name |
string Required. The resource name of the reference list to retrieve.
Format:
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]/referenceLists/[REFERENCE_LIST]";
// Make the request
ReferenceList response = await referenceListServiceClient.GetReferenceListAsync(name);
GetReferenceListAsync(string, CancellationToken)
public virtual Task<ReferenceList> GetReferenceListAsync(string name, CancellationToken cancellationToken)
Gets a single reference list.
Parameters | |
---|---|
Name | Description |
name |
string Required. The resource name of the reference list to retrieve.
Format:
|
cancellationToken |
CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]/referenceLists/[REFERENCE_LIST]";
// Make the request
ReferenceList response = await referenceListServiceClient.GetReferenceListAsync(name);
ListReferenceLists(InstanceName, string, int?, CallSettings)
public virtual PagedEnumerable<ListReferenceListsResponse, ReferenceList> ListReferenceLists(InstanceName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)
Lists a collection of reference lists.
Parameters | |
---|---|
Name | Description |
parent |
InstanceName Required. The parent, which owns this collection of reference lists.
Format:
|
pageToken |
string The token returned from the previous request. A value of |
pageSize |
int The size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
PagedEnumerableListReferenceListsResponseReferenceList |
A pageable sequence of ReferenceList resources. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
InstanceName parent = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
// Make the request
PagedEnumerable<ListReferenceListsResponse, ReferenceList> response = referenceListServiceClient.ListReferenceLists(parent);
// Iterate over all response items, lazily performing RPCs as required
foreach (ReferenceList 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 (ListReferenceListsResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (ReferenceList 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<ReferenceList> 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 (ReferenceList 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;
ListReferenceLists(ListReferenceListsRequest, CallSettings)
public virtual PagedEnumerable<ListReferenceListsResponse, ReferenceList> ListReferenceLists(ListReferenceListsRequest request, CallSettings callSettings = null)
Lists a collection of reference lists.
Parameters | |
---|---|
Name | Description |
request |
ListReferenceListsRequest 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 |
PagedEnumerableListReferenceListsResponseReferenceList |
A pageable sequence of ReferenceList resources. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
ListReferenceListsRequest request = new ListReferenceListsRequest
{
ParentAsInstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
View = ReferenceListView.Unspecified,
};
// Make the request
PagedEnumerable<ListReferenceListsResponse, ReferenceList> response = referenceListServiceClient.ListReferenceLists(request);
// Iterate over all response items, lazily performing RPCs as required
foreach (ReferenceList 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 (ListReferenceListsResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (ReferenceList 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<ReferenceList> 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 (ReferenceList 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;
ListReferenceLists(string, string, int?, CallSettings)
public virtual PagedEnumerable<ListReferenceListsResponse, ReferenceList> ListReferenceLists(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)
Lists a collection of reference lists.
Parameters | |
---|---|
Name | Description |
parent |
string Required. The parent, which owns this collection of reference lists.
Format:
|
pageToken |
string The token returned from the previous request. A value of |
pageSize |
int The size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
PagedEnumerableListReferenceListsResponseReferenceList |
A pageable sequence of ReferenceList resources. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
// Make the request
PagedEnumerable<ListReferenceListsResponse, ReferenceList> response = referenceListServiceClient.ListReferenceLists(parent);
// Iterate over all response items, lazily performing RPCs as required
foreach (ReferenceList 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 (ListReferenceListsResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (ReferenceList 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<ReferenceList> 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 (ReferenceList 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;
ListReferenceListsAsync(InstanceName, string, int?, CallSettings)
public virtual PagedAsyncEnumerable<ListReferenceListsResponse, ReferenceList> ListReferenceListsAsync(InstanceName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)
Lists a collection of reference lists.
Parameters | |
---|---|
Name | Description |
parent |
InstanceName Required. The parent, which owns this collection of reference lists.
Format:
|
pageToken |
string The token returned from the previous request. A value of |
pageSize |
int The size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
PagedAsyncEnumerableListReferenceListsResponseReferenceList |
A pageable asynchronous sequence of ReferenceList resources. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
InstanceName parent = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
// Make the request
PagedAsyncEnumerable<ListReferenceListsResponse, ReferenceList> response = referenceListServiceClient.ListReferenceListsAsync(parent);
// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((ReferenceList 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((ListReferenceListsResponse page) =>
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (ReferenceList 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<ReferenceList> 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 (ReferenceList 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;
ListReferenceListsAsync(ListReferenceListsRequest, CallSettings)
public virtual PagedAsyncEnumerable<ListReferenceListsResponse, ReferenceList> ListReferenceListsAsync(ListReferenceListsRequest request, CallSettings callSettings = null)
Lists a collection of reference lists.
Parameters | |
---|---|
Name | Description |
request |
ListReferenceListsRequest 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 |
PagedAsyncEnumerableListReferenceListsResponseReferenceList |
A pageable asynchronous sequence of ReferenceList resources. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
ListReferenceListsRequest request = new ListReferenceListsRequest
{
ParentAsInstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
View = ReferenceListView.Unspecified,
};
// Make the request
PagedAsyncEnumerable<ListReferenceListsResponse, ReferenceList> response = referenceListServiceClient.ListReferenceListsAsync(request);
// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((ReferenceList 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((ListReferenceListsResponse page) =>
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (ReferenceList 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<ReferenceList> 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 (ReferenceList 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;
ListReferenceListsAsync(string, string, int?, CallSettings)
public virtual PagedAsyncEnumerable<ListReferenceListsResponse, ReferenceList> ListReferenceListsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)
Lists a collection of reference lists.
Parameters | |
---|---|
Name | Description |
parent |
string Required. The parent, which owns this collection of reference lists.
Format:
|
pageToken |
string The token returned from the previous request. A value of |
pageSize |
int The size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
PagedAsyncEnumerableListReferenceListsResponseReferenceList |
A pageable asynchronous sequence of ReferenceList resources. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
// Make the request
PagedAsyncEnumerable<ListReferenceListsResponse, ReferenceList> response = referenceListServiceClient.ListReferenceListsAsync(parent);
// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((ReferenceList 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((ListReferenceListsResponse page) =>
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (ReferenceList 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<ReferenceList> 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 (ReferenceList 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. |
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.
UpdateReferenceList(ReferenceList, FieldMask, CallSettings)
public virtual ReferenceList UpdateReferenceList(ReferenceList referenceList, FieldMask updateMask, CallSettings callSettings = null)
Updates an existing reference list.
Parameters | |
---|---|
Name | Description |
referenceList |
ReferenceList Required. The reference list to update. The reference list's |
updateMask |
FieldMask The list of fields to update. When no field mask is supplied, all non-empty fields will be updated. A field mask of "*" will update all fields, whether empty or not. |
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
ReferenceList |
The RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
ReferenceList referenceList = new ReferenceList();
FieldMask updateMask = new FieldMask();
// Make the request
ReferenceList response = referenceListServiceClient.UpdateReferenceList(referenceList, updateMask);
UpdateReferenceList(UpdateReferenceListRequest, CallSettings)
public virtual ReferenceList UpdateReferenceList(UpdateReferenceListRequest request, CallSettings callSettings = null)
Updates an existing reference list.
Parameters | |
---|---|
Name | Description |
request |
UpdateReferenceListRequest 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 |
ReferenceList |
The RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = ReferenceListServiceClient.Create();
// Initialize request argument(s)
UpdateReferenceListRequest request = new UpdateReferenceListRequest
{
ReferenceList = new ReferenceList(),
UpdateMask = new FieldMask(),
};
// Make the request
ReferenceList response = referenceListServiceClient.UpdateReferenceList(request);
UpdateReferenceListAsync(ReferenceList, FieldMask, CallSettings)
public virtual Task<ReferenceList> UpdateReferenceListAsync(ReferenceList referenceList, FieldMask updateMask, CallSettings callSettings = null)
Updates an existing reference list.
Parameters | |
---|---|
Name | Description |
referenceList |
ReferenceList Required. The reference list to update. The reference list's |
updateMask |
FieldMask The list of fields to update. When no field mask is supplied, all non-empty fields will be updated. A field mask of "*" will update all fields, whether empty or not. |
callSettings |
CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
ReferenceList referenceList = new ReferenceList();
FieldMask updateMask = new FieldMask();
// Make the request
ReferenceList response = await referenceListServiceClient.UpdateReferenceListAsync(referenceList, updateMask);
UpdateReferenceListAsync(ReferenceList, FieldMask, CancellationToken)
public virtual Task<ReferenceList> UpdateReferenceListAsync(ReferenceList referenceList, FieldMask updateMask, CancellationToken cancellationToken)
Updates an existing reference list.
Parameters | |
---|---|
Name | Description |
referenceList |
ReferenceList Required. The reference list to update. The reference list's |
updateMask |
FieldMask The list of fields to update. When no field mask is supplied, all non-empty fields will be updated. A field mask of "*" will update all fields, whether empty or not. |
cancellationToken |
CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
ReferenceList referenceList = new ReferenceList();
FieldMask updateMask = new FieldMask();
// Make the request
ReferenceList response = await referenceListServiceClient.UpdateReferenceListAsync(referenceList, updateMask);
UpdateReferenceListAsync(UpdateReferenceListRequest, CallSettings)
public virtual Task<ReferenceList> UpdateReferenceListAsync(UpdateReferenceListRequest request, CallSettings callSettings = null)
Updates an existing reference list.
Parameters | |
---|---|
Name | Description |
request |
UpdateReferenceListRequest 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 |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateReferenceListRequest request = new UpdateReferenceListRequest
{
ReferenceList = new ReferenceList(),
UpdateMask = new FieldMask(),
};
// Make the request
ReferenceList response = await referenceListServiceClient.UpdateReferenceListAsync(request);
UpdateReferenceListAsync(UpdateReferenceListRequest, CancellationToken)
public virtual Task<ReferenceList> UpdateReferenceListAsync(UpdateReferenceListRequest request, CancellationToken cancellationToken)
Updates an existing reference list.
Parameters | |
---|---|
Name | Description |
request |
UpdateReferenceListRequest The request object containing all of the parameters for the API call. |
cancellationToken |
CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
TaskReferenceList |
A Task containing the RPC response. |
// Create client
ReferenceListServiceClient referenceListServiceClient = await ReferenceListServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateReferenceListRequest request = new UpdateReferenceListRequest
{
ReferenceList = new ReferenceList(),
UpdateMask = new FieldMask(),
};
// Make the request
ReferenceList response = await referenceListServiceClient.UpdateReferenceListAsync(request);