Skip to content

Instantly share code, notes, and snippets.

@sienatime
Created November 11, 2018 20:43
Show Gist options
  • Save sienatime/fa0303e8a2ccce05706b44ab4df4b2f5 to your computer and use it in GitHub Desktop.
Save sienatime/fa0303e8a2ccce05706b44ab4df4b2f5 to your computer and use it in GitHub Desktop.
public LiveData<PagedList<SearchResultEntry>> search(String term) {
String wildcardQuery = String.format("*%s*", term);
return new LivePagedListBuilder<>(entryDao.searchByJapaneseTerm(wildcardQuery), PAGE_SIZE).build();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment