From the course: Android App Development: Design Patterns for Mobile Architecture

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Entities

Entities

- [Narrator] We've moved all the logic out of the Presenter into their other layers, but we're still tightly coupled because we're using a Realm spy object. And we really should be using that Realm DTO object that we have been using just to translate from JSON. So, the best thing to do is to just go through every place that we're using that, that we shouldn't be, And let's start with the SpyListPresenter. In here we're going to just replace Spy with the SpyDTO, and this is basically what we're going to do everywhere throughout the application. We'll go into the DetailsPresenter. Let's go ahead and autoscroll. Turn on these attributes. And in here we are passing out the spy. So we'll just change this to a spy. And we'll bring that in. Gender we'll just say name. We'll go to the SecretDetailsPresenter. And there's really not a logic or discussion other than just having to do the brute work here. We'll worry about the error on line 20 when we go down into the ModelLayer. Just go into the…

Contents