Skip to content

Instantly share code, notes, and snippets.

@leandroBorgesFerreira
Last active December 18, 2018 14:07
Show Gist options
  • Select an option

  • Save leandroBorgesFerreira/37a8cfc289b96ba414857f36c1393492 to your computer and use it in GitHub Desktop.

Select an option

Save leandroBorgesFerreira/37a8cfc289b96ba414857f36c1393492 to your computer and use it in GitHub Desktop.
class RepositoryUseCase<F>(
private val dataSource: RepositoryDataSource<F>
) : Kind<F, List<Repository>>, Async<F> by dataSource{
fun getRepositories() : Kind<F, List<Repository>> =
dataSource.fetchAllRepositories().continueOn(Dispatchers.Main)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment