numberOfResults property
int
numberOfResults
Total number of results found.
Implementation
int get numberOfResults {
// calculate from raw response
if (this.raw != null && this.raw!.containsKey('hits')) {
if (this.raw != null &&
this.raw!['hits'] != null &&
this.raw!['hits']['total'] != null) {
if (this.raw!['hits']['total'] is Map) {
return this.raw!['hits']['total']['value'];
}
if (this.raw!['hits']['total'] is int) {
return this.raw!['hits']['total'];
}
}
}
return 0;
}