I'm using MVP design pattern in an android studio app. I have login and signup activities which both have some functions which are the same. Is there a way no to copy paste the same functions from one view to the other one?
Asked
Active
Viewed 80 times
1 Answers
0
Since you're using MVP, you can make that common function in your presenter and then use it for login and signup. Hope it helps! :)

Alok Bharti
- 136
- 1
- 8
-
Those functions are not a logic functions so they must be in the view. Those functions are functions the change the view. – Noam Simon Jan 11 '20 at 09:26
-
So make a common function in the Activity outside of the onCreate method and then you can use it for both. – Alok Bharti Jan 11 '20 at 09:30