SearchResponse class

This class holds the response from the search query.

success is indicative of whether the query was a success (i.e. no error was thrown). results contains the query results for the given text. offset is used for pagination and should be provided in the search function as a parameter. searchInfo will contain general information about the query. rawResponse stores the raw json body response.

Constructors

SearchResponse({required bool success, required Map<String, dynamic> rawResponse, List<SearchResult>? results, int? offset, SearchInfo? searchInfo})
const
SearchResponse.fromJson(String source)
factory
SearchResponse.fromMap(Map<String, dynamic> map)
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
offset int?
final
rawResponse Map<String, dynamic>
final
results List<SearchResult>?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
searchInfo SearchInfo?
final
success bool
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() String
toMap() Map<String, dynamic>
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited