What is the use of implementing a class from BaseColumns
in Android?
It is an interface, which looks like this
public interface BaseColumns
{
public static final String _ID = "_id";
public static final String _COUNT = "_count";
}
It contains constants like id and count used for auto-increment in SQL lite DB.
We can also create our own constants for id without using this particular interface. But functions like cursor adaptor requires the exact constants like "_id", So it is better to use the provided interface!!
Hope this helps you out!! :-)