BoD / android-contentprovider-generator

A tool to generate Android ContentProviders.
GNU General Public License v3.0
619 stars 151 forks source link

Method errors in generated code of v1.9.3 #89

Closed thvranken closed 9 years ago

thvranken commented 9 years ago

I get following errors in Android Studio when using the code generated by android-contentprovider-generator 1.9.3, with "TableName" being the provided name for a database table:

error: method orderById(boolean) is already defined in class TableNameSelection error: method orderById() is already defined in class TableNameSelection error: method getId() is already defined in class TableNameCursor error: TableNameCursor is not abstract and does not override abstract method getId() in TableNameModel error: getId() in TableNameCursor cannot implement getId() in TableNameModel return type long is not compatible with Integer

thvranken commented 9 years ago

Found the problem. These errors occur when you define a column with name "id".

BoD commented 9 years ago

Thanks for the report. I guess this should be documented, but indeed, this name is kind of "invalid" :) (because it conflicts with the implicit "_id" column). So closing this issue for now.