2.0 has been re-written from scratch. API surface has been revamped completely and it might require lot of changes on your code to update. Good news is, you can keep both 1.x and 2.x versions inside the same app and migrate one adapter at a time.
To allow having 1.x and 2.x work side by side, MultiViewAdapter 2.0 has been uploaded with new artifact name. Also the package names are changed to facilitate the same.
Name | 1.x | 2.x |
---|---|---|
Adapter | com.github.devahamed:multi-view-adapter:1.3.0 | dev.ahamed.mva2:adapter:2.0.0 |
Databinding extension | com.github.devahamed:multi-view-adapter-databinding:1.3.0 | dev.ahamed.mva2:ext-databinding:2.0.0 |
Decorator extension | NA | dev.ahamed.mva2:ext-decorator:2.0.0 |
RxDiffUtil extension | NA | dev.ahamed.mva2:ext-diffutil-rx:2.0.0 |
1.x | 2.x | |
---|---|---|
Adapter | com.ahamed.multiviewadapter.* | mva2.adapter.* |
Extension | com.ahamed.multiviewadapter.* | mva2.extension.* |
We regret about introducing lot of ambiguity and confusion while naming our components. During 2.x rewrite, major time was spent on naming the classes and public api methods. One of the major change is DataManager variants are renamed to Section. Previously, DataManager variants are named like Data*Manager, like DataItemManager, DataListManager etc., Now they are named as *Section. (ItemSection, ListSection)
Component naming changes
1.x | 2.x | Comments |
---|---|---|
Adapter | ||
RecyclerAdapter | MultiViewAdapter | |
SelectableAdapter | Removed | Use MultiViewAdapter instead |
SimpleRecyclerAdapter | Removed | Coming as an extension |
DataManager | ||
BaseDataManager | Section | |
DataItemManager | ItemSection | |
DataListManager | ListSection | |
DataGroupManager | HeaderSection | |
Decorator | ||
ItemDecorationManager | DecorationManager | |
ItemDecorator | Decorator | Previously it was an interface, now an abstract class |
SimpleDividerDecoration | Removed | Use 'Decorator' extension |
PositionTypeResolver | Removed | Merged into Decorator class |
Listeners | ||
ItemSelectionChangedListener | Removed | Use OnSelectionChangedListener instead |
MultiSelectionChangedListener | OnSelectionChangedListener | |
Others | ||
ItemBinderTouchCallback | ItemTouchCallback | |
Enums | ||
SelectionMode | Mode | |
Expandable | Mode |
- OnClickListener and OnLongClickListener has been removed from the library.
- Set selected items feature has been removed.
- SimpleRecyclerAdapter has been removed.