listCandidatesForAutoMLJob method
Future<ListCandidatesForAutoMLJobResponse>
listCandidatesForAutoMLJob({
- required String autoMLJobName,
- String? candidateNameEquals,
- int? maxResults,
- String? nextToken,
- CandidateSortBy? sortBy,
- AutoMLSortOrder? sortOrder,
- CandidateStatus? statusEquals,
List the Candidates created for the job.
May throw ResourceNotFound.
Parameter autoMLJobName
:
List the Candidates created for the job by providing the job's name.
Parameter candidateNameEquals
:
List the Candidates for the job and filter by candidate name.
Parameter maxResults
:
List the job's Candidates up to a specified limit.
Parameter nextToken
:
If the previous response was truncated, you receive this token. Use it in
your next request to receive the next set of results.
Parameter sortBy
:
The parameter by which to sort the results. The default is Descending.
Parameter sortOrder
:
The sort order for the results. The default is Ascending.
Parameter statusEquals
:
List the Candidates for the job and filter by status.
Implementation
Future<ListCandidatesForAutoMLJobResponse> listCandidatesForAutoMLJob({
required String autoMLJobName,
String? candidateNameEquals,
int? maxResults,
String? nextToken,
CandidateSortBy? sortBy,
AutoMLSortOrder? sortOrder,
CandidateStatus? statusEquals,
}) async {
ArgumentError.checkNotNull(autoMLJobName, 'autoMLJobName');
_s.validateStringLength(
'autoMLJobName',
autoMLJobName,
1,
32,
isRequired: true,
);
_s.validateStringLength(
'candidateNameEquals',
candidateNameEquals,
1,
64,
);
_s.validateNumRange(
'maxResults',
maxResults,
1,
100,
);
_s.validateStringLength(
'nextToken',
nextToken,
0,
8192,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'SageMaker.ListCandidatesForAutoMLJob'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'AutoMLJobName': autoMLJobName,
if (candidateNameEquals != null)
'CandidateNameEquals': candidateNameEquals,
if (maxResults != null) 'MaxResults': maxResults,
if (nextToken != null) 'NextToken': nextToken,
if (sortBy != null) 'SortBy': sortBy.toValue(),
if (sortOrder != null) 'SortOrder': sortOrder.toValue(),
if (statusEquals != null) 'StatusEquals': statusEquals.toValue(),
},
);
return ListCandidatesForAutoMLJobResponse.fromJson(jsonResponse.body);
}