Skip to content

Instantly share code, notes, and snippets.

@DenisBronx
Created September 3, 2019 22:51
Show Gist options
  • Save DenisBronx/1c8adba79604976f180a89e300e15236 to your computer and use it in GitHub Desktop.
Save DenisBronx/1c8adba79604976f180a89e300e15236 to your computer and use it in GitHub Desktop.
Repository Pattern DB DTO
// Database DTO
@Entity(tableName = "Product")
data class DBProduct(
@PrimaryKey
@ColumnInfo(name = "id")
val id: String,
@ColumnInfo(name = "name")
val name: String,
@ColumnInfo(name = "nowPrice")
val nowPrice: Double,
@ColumnInfo(name = "wasPrice")
val wasPrice: Double
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment