Hi Rohit, thanks for reading this post, hope you found it interesting. I’m afraid I don’t have a sample project for this structure, but I think that almost the whole code is exposed in this post (except the VC). The structure follow this way:
- UI Layer: VC+Presenter
- Domain Layer: UseCase+RepositoryProtocol
- Data layer: DataRepository+DataSource
Hi Karthik! First of all, thanks for reading this post. That’s a very good question indeed, it could be subject of future post.
I can’t provide you a detailed implementation just now, but here goes an idea:
I would create a boolean in my custom
SessionManagerclass that indicates if token is refreshing and an array of custom request objects…