searchContent method

Future<SearchList<BaseSearchContent>> searchContent(
  1. String searchQuery, {
  2. SearchFilter filter = const SearchFilter(''),
})

Enumerates results returned by the specified search query. The contents are sent in batch of 20 elements. The list can either contain a SearchVideo, SearchPlaylist or a SearchChannel. You SearchList.nextPage to get the next batch of content.

Implementation

Future<SearchList> searchContent(String searchQuery,
    {SearchFilter filter = const SearchFilter('')}) async {
  final page = await SearchPage.get(_httpClient, searchQuery, filter: filter);

  return SearchList(page.searchContent, page, _httpClient);
}