google / google/ground-android

[Code health] Consistent naming of local DB converters

Open
#1,276 16 comments 0 reactions 0 assignees View on GitHub
type: code health
Dominant language
Kotlin
Stars
293
Forks
149
Avg merge
1d 16h
Merged PRs (30d)
42

Description

Pretty much every local db entity has to/from conversion methods for converting a corresponding model object to the local db entity type. However, we don't name these consistently. Sometimes they are named `toModel`, sometimes `toObject` sometimes `to`...

We should pick a consistent naming scheme. For extra clarity, my vote goes toward `toModel`; e.g.

`toLocationOfInterestModel`; `fromLocationOfInterestModel`; `toAuditInfoModel`; `fromAuditInfoModel`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.