chore: [ANDROSDK-2333] migrate conflict and data value models to kotlin#2648
Merged
Conversation
vgarciabnz
reviewed
Jun 26, 2026
| data class DataValue( | ||
| override val syncState: State?, | ||
| override val deleted: Boolean?, | ||
| val dataElement: String?, |
Member
There was a problem hiding this comment.
We could try to make these 5 properties non-null. They are non-null in the DTO and they are the primary key in the DB. Maybe it has more implications that I don't see now.
vgarciabnz
reviewed
Jun 26, 2026
| data class DataValueConflict( | ||
| val conflict: String?, | ||
| val value: String?, | ||
| val attributeOptionCombo: String?, |
Member
There was a problem hiding this comment.
Same here, these 5 properties are non-null in the db. This class is only generated internally in the SDK (it does not come from the API).
vgarciabnz
requested changes
Jun 26, 2026
remove unnecessary non null assertions
remove unnecessary non null assertions
vgarciabnz
reviewed
Jun 29, 2026
| dataValue.dataElement(), | ||
| dataValue.categoryOptionCombo(), | ||
| dataValue.attributeOptionCombo(), | ||
| DataValueInternalAccessor.accessSourceDataSet(dataValue)!!, |
Member
There was a problem hiding this comment.
This internal accessor, could it be removed?
|
vgarciabnz
approved these changes
Jun 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.



Migrates the import/data-value conflict models and the
DataValuemodel from Java AutoValue to Kotlin data classes using the@ModelBuilderannotation, continuing the model-migration effort (batch 15).TrackerImportConflictandDataValueConflictare straightforwardCoreObjectconversions.DataValueextendsBaseDeletableDataObject, so it follows theEventprecedent: it now implementsDataObjectKt/DeletableDataObjectKtwithsyncState/deletedproperties, and the builder'sSYNCED/falsedefaults are preserved in thebuilder()factory to keep behavior identical across all construction paths.Related task: ANDROSDK-2333