MVP classes generator
This plugin generates required presenter and view classes for a Fragment or Activity easing the burden to create those classes manually.
Following classes are required for the generated classes to have correct inheritance. It's in pipeline to auto generate these files also, if not found. You can specify your own names for the following required Base classes and interfaces using the Settings icon.
- For New Fragment :
- Scene - common interface for all fragments
- Presenter - common interface for all Fragment Presenters.
- BaseFragment - abstract base Fragment class which every fragment will inherit from.
- BasePresenterImpl implements FragmentPresenter - base abstract class from which all Fragment Presenters will inherit.
- For New Activity :
- ActivityScene - interface for all activities.
- ActivityPresenter - common interface for all Activity Presenter.
- BaseActivity - abstract base class for all activities.
- BaseActivityPresenterImpl implements ActivityPresenter - Base Abstract implementation of Activity Presenter which all Activity Presenters will subclass.
How to use?
- From inside of any
Fragment open generate menu(ALT + INSERT, CMD/CTRL + N).
create mvp option.
- Select the appropriate packages for the API and Implementation Generation.
- Press OK, voila! your files are generated.