Changeset View
Changeset View
Standalone View
Standalone View
src/it/reyboz/bustorino/data/gtfs/GtfsShape.kt
- This file was added.
package it.reyboz.bustorino.data.gtfs | |||||
import androidx.room.ColumnInfo | |||||
import androidx.room.Entity | |||||
@Entity(tableName = GtfsShape.DB_TABLE, | |||||
primaryKeys = [GtfsShape.COL_SHAPEID, GtfsShape.COL_POINT_SEQ]) | |||||
data class GtfsShape( | |||||
@ColumnInfo(name = COL_SHAPEID) | |||||
val shapeID: String, | |||||
@ColumnInfo(name = COL_POINT_LAT) | |||||
val pointLat: Double, | |||||
@ColumnInfo(name = COL_POINT_LON) | |||||
val pointLon: Double, | |||||
@ColumnInfo(name = COL_POINT_SEQ) | |||||
val pointSequence: Int, | |||||
){ | |||||
companion object{ | |||||
const val DB_TABLE="gtfs_shapes" | |||||
const val COL_SHAPEID = "shape_id" | |||||
const val COL_POINT_LAT="shape_pt_lat" | |||||
const val COL_POINT_LON="shape_pt_lon" | |||||
const val COL_POINT_SEQ="shape_pt_sequence" | |||||
val COLUMNS= arrayOf( | |||||
COL_SHAPEID, | |||||
COL_POINT_LAT, | |||||
COL_POINT_LON, | |||||
COL_POINT_SEQ | |||||
) | |||||
} | |||||
} |
Public contents are in Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) or GNU Free Documentation License (at your option) unless otherwise noted. · Contact / Register