Added useCamelCaseNameWithoutInsertions #394
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I am currently working on several apps where I use greenDao to access a Sqlite database created by another module. This database does not include underscores in table and property names which consist of more than one word e.g.
DELETEDDATE
.A solution for this issue would be to not use camel casing in the code’s table and property names e.g.
addDateProperty("Deleteddate")
, but this looks weird and does not fall in line with Google’s Java Style Guide Chapter 5.2.5 (https://google.github.io/styleguide/javaguide.html).Another solution would be to use camel casing in the code’s table and property names and additionally specify the database naming e.g.
addDateProperty("DeletedDate").columnName("DELETEDDATE")
, but this approach is quite a hassle for a large amount of tables and properties (I can provide you with some examples).Thus I implemented the possibility to generally switch off the underscore insertion for table and property names.
Feel free to accept the pull request if you like the changes, or ask me for further information.