listFeatureGroups method

Future<ListFeatureGroupsResponse> listFeatureGroups({
  1. DateTime? creationTimeAfter,
  2. DateTime? creationTimeBefore,
  3. FeatureGroupStatus? featureGroupStatusEquals,
  4. int? maxResults,
  5. String? nameContains,
  6. String? nextToken,
  7. OfflineStoreStatusValue? offlineStoreStatusEquals,
  8. FeatureGroupSortBy? sortBy,
  9. FeatureGroupSortOrder? sortOrder,
})

List FeatureGroups based on given filter and order.

Parameter creationTimeAfter : Use this parameter to search for FeatureGroupss created after a specific date and time.

Parameter creationTimeBefore : Use this parameter to search for FeatureGroupss created before a specific date and time.

Parameter featureGroupStatusEquals : A FeatureGroup status. Filters by FeatureGroup status.

Parameter maxResults : The maximum number of results returned by ListFeatureGroups.

Parameter nameContains : A string that partially matches one or more FeatureGroups names. Filters FeatureGroups by name.

Parameter nextToken : A token to resume pagination of ListFeatureGroups results.

Parameter offlineStoreStatusEquals : An OfflineStore status. Filters by OfflineStore status.

Parameter sortBy : The value on which the feature group list is sorted.

Parameter sortOrder : The order in which feature groups are listed.

Implementation

Future<ListFeatureGroupsResponse> listFeatureGroups({
  DateTime? creationTimeAfter,
  DateTime? creationTimeBefore,
  FeatureGroupStatus? featureGroupStatusEquals,
  int? maxResults,
  String? nameContains,
  String? nextToken,
  OfflineStoreStatusValue? offlineStoreStatusEquals,
  FeatureGroupSortBy? sortBy,
  FeatureGroupSortOrder? sortOrder,
}) async {
  _s.validateNumRange(
    'maxResults',
    maxResults,
    1,
    100,
  );
  _s.validateStringLength(
    'nameContains',
    nameContains,
    1,
    64,
  );
  _s.validateStringLength(
    'nextToken',
    nextToken,
    0,
    8192,
  );
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'SageMaker.ListFeatureGroups'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      if (creationTimeAfter != null)
        'CreationTimeAfter': unixTimestampToJson(creationTimeAfter),
      if (creationTimeBefore != null)
        'CreationTimeBefore': unixTimestampToJson(creationTimeBefore),
      if (featureGroupStatusEquals != null)
        'FeatureGroupStatusEquals': featureGroupStatusEquals.toValue(),
      if (maxResults != null) 'MaxResults': maxResults,
      if (nameContains != null) 'NameContains': nameContains,
      if (nextToken != null) 'NextToken': nextToken,
      if (offlineStoreStatusEquals != null)
        'OfflineStoreStatusEquals': offlineStoreStatusEquals.toValue(),
      if (sortBy != null) 'SortBy': sortBy.toValue(),
      if (sortOrder != null) 'SortOrder': sortOrder.toValue(),
    },
  );

  return ListFeatureGroupsResponse.fromJson(jsonResponse.body);
}