Skip to content

Instantly share code, notes, and snippets.

@michalbujalski
Last active January 21, 2019 06:20
Show Gist options
  • Save michalbujalski/aab5e3512464fcaf533831394ce283c0 to your computer and use it in GitHub Desktop.
Save michalbujalski/aab5e3512464fcaf533831394ce283c0 to your computer and use it in GitHub Desktop.
data class Contact(val name:String, val phoneNum:String)
interface ContactsListsApi{
fetchContacts(): Single<List<Contact>>
}
interface ContactsListsContract{
interface View{
fun showProgress()
fun hideProgress()
fun setData(contacts: List<Contact>)
}
interface Presenter{
fun fetchContacts()
}
}
class ContactsListPresenter(val view: ContactsListsContract.View, val api:ContactsListsApi): ContactsListsContract.Presenter {
override fun fetchContacts(){
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment