list method
Returns a list of all generic objects for a given issuer ID.
Request parameters:
classId
- The ID of the class whose objects will be listed.
maxResults
- Identifies the max number of results returned by a list.
All results are returned if maxResults
isn't defined.
token
- Used to get the next set of results if maxResults
is
specified, but more than maxResults
objects are available in a list. For
example, if you have a list of 200 objects and you call list with
maxResults
set to 20, list will return the first 20 objects and a token.
Call list again with maxResults
set to 20 and the token to get the next
20 objects.
$fields
- Selector specifying which fields to include in a partial
response.
Completes with a GenericObjectListResponse.
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<GenericObjectListResponse> list({
core.String? classId,
core.int? maxResults,
core.String? token,
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
if (classId != null) 'classId': [classId],
if (maxResults != null) 'maxResults': ['${maxResults}'],
if (token != null) 'token': [token],
if ($fields != null) 'fields': [$fields],
};
const url_ = 'walletobjects/v1/genericObject';
final response_ = await _requester.request(
url_,
'GET',
queryParams: queryParams_,
);
return GenericObjectListResponse.fromJson(
response_ as core.Map<core.String, core.dynamic>);
}