A detailed guide on developing Android apps using the Clean Architecture pattern
Dario Miličić

Hello, Dario! I started rewriting my app using your boilerplate code and it working great and my code look so much cleaner :).

But I’m stuck on one part. I’ve got one question. How would you write your repository interface if you were using a dynamic database like Firebase and its listeners? Let’s assume for example this use case : Add a book to my shelves if it’s not already added. After or if it is, add it to or update the local database for offline use, then notify operation is complete.

Now I’m just passing the presenter, which implements the interactor callback, down to the repository implementation. And I dont know how to use the realtime part of firebase with this architecture while keeping the no dependency rule.

And thanks for this article.