xaverkapeller / sortedlistadapter Goto Github PK
View Code? Open in Web Editor NEWThe RecyclerView.Adapter that makes your life easy!
Home Page: https://wrdlbrnft.github.io/SortedListAdapter/
License: MIT License
The RecyclerView.Adapter that makes your life easy!
Home Page: https://wrdlbrnft.github.io/SortedListAdapter/
License: MIT License
在 Android studio 中怎么添加混淆?
Hello.
Is there any way to support different viewTypes that doesn't extends Model like AdExpressViewHolder ?
The problem is that in your implementation onCreateViewHolder must return something that extend Model class
ViewHolder<? extends ExampleModel> onCreateViewHolder
Is it possible in my situation ?
@Override
public RecyclerView.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
final View v = inflater.inflate(viewType, parent, false);
if (viewType == VIEW_TYPE_COLLAPSED) {
return new CollapsedVH(v, this);
} else if (viewType == VIEW_TYPE_EXPANDED) {
return new ExpandedVH(v, this);
} else if (viewType == VIEW_TYPE_AD_EXPRESS) {
return new AdExpressViewHolder(v);
} else return null;
}
I'm interested in using SortedListAdapter for a project but I didn't see any licensing information.
I'm attempting to use SortedListAdapter, and everything seems to be working great, except that occasionally when I call replaceAll with items that should satisfy isSameModelAs == true
, a duplicate entry will appear for a moment before being removed.
Is this intended, and is there a way to modify this behaviour? I am currently checking against a unique id field (a MAC address) in my implmentation of isSameModelAs
Hi!
I'm not familiar with DataBinding. How can i bind to diffrent xml layouts? Normally i can change the layout xml in the onCreateViewHolder function:
inflater.inflate(R.layout.example, parent, false);
How can i change the ViewType and the ViewHolder based on the Model.getName() function or other criteria? I'm very open for good suggestions.
Thx for your help.
@Wrdlbrnft What is the purpose of ViewModel interface?
HI I was wondering will this work with android architectural components viewmodel
I am a big fan of your sortedListAdapter, I have implemented search and databinding and I am very pleased with the results. I would now like to implement swipe to delete, but I am unsure of how to do it, can you help me?
final List filteredModelList = filter(contacts, query);
mAdapter.edit()
.replaceAll(filteredModelList)
.commit();
It is not replacing the filtered list, I dont have any log information, it was working previously, I already debuged the filteredList has the values filtered but the replaceAll is not working, do you know if its working with API level 26?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.