with gradle
compile 'com.github.donniesky:Walle:0.1.1'
Assuming you have installed jitpack provider:
allprojects {
repositories {
jcenter()
maven { url "https://jitpack.io" }
}
}
or just import Walle
module to your project.
Proxy Pattern.
- No need change anything with your target adapter;
- Not destory target adapter position;
- Support dynamic add & remove;
- No dependencies code build order
Walle wrapper = Walle.newBuilder()
.wrapperAdapter(adapter)
.autoLoadMore(false)
.headerViewRes(R.layout.view_header)
.emptyViewRes(R.layout.view_empty)
.footerViewRes(R.layout.view_footer)
.loadMoreViewRes(R.layout.view_loadmore)
.build();
- baseAdapter hongyangAndroid/baseAdapter
- BaseRecyclerViewAdapterHelper CymChad/BaseRecyclerViewAdapterHelper
- 更优雅的方式添加 Header 与 Footer 优雅的添加Header和Footer等