searchEntries method
Searches for Entries matching the given query and scope.
Request parameters:
name
- Required. The project to which the request should be attributed
in the following form: projects/{project}/locations/{location}.
Value must have pattern ^projects/\[^/\]+/locations/\[^/\]+$
.
orderBy
- Optional. Specifies the ordering of results. Supported values
are: relevance (default) last_modified_timestamp last_modified_timestamp
asc
pageSize
- Optional. Number of results in the search page. If <=0, then
defaults to 10. Max limit for page_size is 1000. Throws an invalid
argument for page_size > 1000.
pageToken
- Optional. Page token received from a previous SearchEntries
call. Provide this to retrieve the subsequent page.
query
- Required. The query against which entries in scope should be
matched. The query syntax is defined in Search syntax for Dataplex Catalog
(https://cloud.google.com/dataplex/docs/search-syntax).
scope
- Optional. The scope under which the search should be operating.
It must either be organizations/ or projects/. If it is unspecified, it
defaults to the organization where the project provided in name is
located.
$fields
- Selector specifying which fields to include in a partial
response.
Completes with a GoogleCloudDataplexV1SearchEntriesResponse.
Completes with a commons.ApiRequestError if the API endpoint returned an error.
If the used http.Client
completes with an error when making a REST call,
this method will complete with the same error.
Implementation
async.Future<GoogleCloudDataplexV1SearchEntriesResponse> searchEntries(
core.String name, {
core.String? orderBy,
core.int? pageSize,
core.String? pageToken,
core.String? query,
core.String? scope,
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
if (orderBy != null) 'orderBy': [orderBy],
if (pageSize != null) 'pageSize': ['${pageSize}'],
if (pageToken != null) 'pageToken': [pageToken],
if (query != null) 'query': [query],
if (scope != null) 'scope': [scope],
if ($fields != null) 'fields': [$fields],
};
final url_ = 'v1/' + core.Uri.encodeFull('$name') + ':searchEntries';
final response_ = await _requester.request(
url_,
'POST',
queryParams: queryParams_,
);
return GoogleCloudDataplexV1SearchEntriesResponse.fromJson(
response_ as core.Map<core.String, core.dynamic>);
}