Details
-
Improvement
-
Status: Resolved
-
Minor
-
Resolution: Complete
-
1.2.0.RELEASE, 1.2.1.RELEASE, 1.2.2.RELEASE
-
All environments
Description
Currently all views inherit from ProxyEditView and utilize activities the inherit ProxyEditView.Delegate. If you want to add a new method to a view or activity, there is no effective way of doing so.
Consider the following example. An application is used to create orders. Each order has a customer that is stored separately. Customers can be reused. Being able to search for a customer while editing the order would be helpful. However, to do so, the method needs to be available in the activity. You could add the method to the ProxyEditView or Delegate, but then it is added to every view.
Changing the inheritance chain of the views to include a separate view interface allows the developer to add custom methods to each view.
ProxyEditView -> EntityEditView -> EntityEditViewImpl
ProxyEditView -> EntityEditView -> MobileEntityEditView
Similarly, modifying the inheritance chain of the delegate and creating a new EditActivity class allows the user to create custom methods in each activity.
ProxyEditView.Delegate -> EntityEditView.Delegate -> EntityEditActivity