Skip to content

Instantly share code, notes, and snippets.

@enginebai
Last active April 1, 2019 00:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save enginebai/2826b87f8aacf13cf4267f19e34b09e2 to your computer and use it in GitHub Desktop.
Save enginebai/2826b87f8aacf13cf4267f19e34b09e2 to your computer and use it in GitHub Desktop.
interface PostRepository {
fun getNewPostList(): Observable<List<NewPost>>
// ...
}
class PostRepositoryImpl : PostRepository {
private val localDataSource: NewPostDao by inject()
override fun getNewPostList(): Observable<List<NewPost>> {
return localDataSource.getAll()
}
// ...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment