Releases: agrosner/DBFlow
Releases · agrosner/DBFlow
4.0.5
- Move the
GeneratedDatabaseHolderoff the last round, warnings should be gone! - Update Kotlin to 1.1.3-2
- update Gradle plugin to 2.3.3 (3.0.0-beta currently breaks robolectric unit testing)
- Some new extensions
- add
Property.allProperty(MyTable.class)so you can easily specifyMyTable.*in a query. - Some optimizations on generated code including removing some redundant null checking.
- Fix issue where
DatabaseStatementin update were not closed when used in aModelAdapter.saveAll()method. - Fix package private
ModelViewthat duplicated field definitions in generated_ViewTableclass. - RXJava2: Change
SingletoMaybefor nullable returns.
4.0.4
- Even better Kotlin support. if a field is not null in Kotlin or using the
android.support.annotation.NonNull/org.jetbrains.annotations.NotNullannotation, we will not attempt to assign a null value on it when theCursorcontains a null value. Primitives always did this of course, but now its expanded to any time. - Fixed a bug by throwing a compiler error if you reference another class in another package that has package private fields, yet its not annotated with
@Table,@ModelView, or@QueryModel. You must make it public or getter/setter private. - Fix nullable
Floatfields not compiling. - Add
BigIntegerConverterto the lib! - Fix issue where primary keys of a reference
@PrimaryKeyhas the same name as the calling table, i.e. both havingidas a column name in the generatedModelAdaptercode. - Fix issue where generated
@ManyToManyreferenced tables that had primary keys withTypeConverternot properly calling typeconverter, leading to compile errors. - Fix issue where a table with
cachingEnabled=truewith astubbedRelationshiptable where the object that calls load called the same instance from the cache (effectively not doing anything), and did not reload its fields from the DB. - More bug fixes + improvements.
4.0.3
4.0.2
- Fix issue where enums broke the processor. #enumsmatter
- Replace
ContentValueswithDatabaseStatementfor updating models, this results in a 33%-50% speed increase! - More
@NonNulland@Nullableannotations - Delete queries also use generated
DatabaseStatement, speeding up bulk deletes. - Add notnull to
@InteritedColumnannotations. - RXJava
observeOnTableChanges()updates. eachModelNotifierhas common interface for interaction. ModelChangeListenerforDirectModelNotifiernow usesOnTableChangeListener.onTableChanged()which adds aClassfor which table changed. This enables better consolidation of interfaces.OnTableChangedListenerpromoted to top-level interface.
4.0.1
4.0.0
Major new release.
Some of the major changes:
- Code generation significantly reduced. more than ~40% reduction in lines of code. Also order is deterministic and always the same in output.
Condition->OperatorincludingConditionGroup->OperatorGroup- Rewrote a lot of annotation processor with KPoet and now 99% Kotlin!
- Much better Kotlin support via
@NonNulland@Nullableannotations on most public api methods. - Can supply a different way to notify observers of changes via the new
DirectModelNotifieror legacyContentResolverNotifier - Remove
Modelrestriction from the library. Classes no longer need to implementModel. Kotlin consumers can take advantage of extension methods inkotlin-extensionsto make classes act likeModel. - Latest plugins + Kotlin 1.1.2
PrimaryKeycan have type converters.ForeignKeyContaineris replaced with@ForeignKey(stubbedRelationship = true). UseModel.load()to get same functionality as before, without the confusion!
10 . RemovedModelContainerimplementation and support. Since removing support, the annotation processor is cleaner and easier to maintain.- Added RXJava1 + 2 support via sub-packages, with corresponding Kotlin extension libraries.
- New documentation website here
- Bug fixes, documentation updates, and more.
4.0.0-beta7
Fixes issue where the rx, rx2, and corresponding Kotlin extensions for each did not publish to JitPack.
4.0.0-beta6
This should be last beta before 4.0.0 if no serious issues.
- rewrite unit tests - most classes are tested. more tests will follow
Conditionare nowOperator, this includesSQLCondition->SQLOperator,ConditionGroup->OperatorGroup.Operatorare now typed and safer to use.
->Operatornow also havediv,times,rem,plusandminusmethods.- Property class changes:
-> All primitivePropertyclasses have been removed. We already boxed the values internally
anyways so removing them cut down on method count and maintenance.
->BasePropertyno longer needs to exist, so all of it's methods now exist inProperty
->modmethod is nowrem(remainder) method to match Kotlin 1.1's changes.
->dividedByis nowdivto match Kotlin operators.
->multipliedByis nowtimesto match Kotlin operators. - Add KPoet to Annotation processor to make processing code more readable.
- Many More Kotlin extension methods
- Code output is deterministic, meaning always in same order unless generated files are added or removed.
- Reduce code generation further in this branch.
- Add a bunch of
@Nullableand@NonNullannotations to public api members to better support Kotlin. - Abstracted out the default Model notification system to allow you to override how its done. the options include
ContentResolverNotifier(default, previous implementation wrapped in new), orDirectModelNotifier- receive changes with theModeldirectly.
4.0.0-beta5
Attempt to republish beta4.
4.0.0-beta4
- Close insert
SQLiteStatementfromModelAdapterwhen resetting DB. @QueryModel+@ModelViewno longer require theirBaseQueryModel+BaseModelViewbase classes.- Added ability to specify
allowedSubTypesinTypeConverter, meaning subclasses of types can all register to same typeconverter. - Allow user override of default
TypeConvertersby declaring usual custom converter with the@TypeConverterannotation. - Cut libs method count footprint by ~100. Library now stands at 2278 methods. Also cut down on generated code + generated code method references when some method overrides were generated even when not actually used for custom behavior in
ModelAdapter. - Methods Added: Add
nullIf()andifNull()methods. Supportstrftime(),date(), anddatetime()methods. - Can now disable caching for models with caching enabled in certain queries via:
select().from(MyTable.class)
.disableCaching()
.queryList()- save, delete, + update methods in
Model+ModelAdapterall returnbooleanfor success / failure. - Can specify custom db extension via
@Database(databaseExtension = )
10 .ProcessModelinterface method now adds aDatabaseWrapper:processModel(Model, DatabaseWrapper - Can do async
insert,update, anddeletevia:
insert(MyTable.class)
.columns(...)
.values(...)
.async()
.execute()- Minor bug fixes + code stability improvements.