abstract class GBDatabase : RoomDatabase
Room database for Gym Buddy app it uses singleton design pattern, it will only create one instance at all time schema information will be exported to '../app/schemas/' whenever database version update
Author
Chia Yu
Since
2019-09-14
<init> |
Room database for Gym Buddy app it uses singleton design pattern, it will only create one instance at all time schema information will be exported to '../app/schemas/' whenever database version update GBDatabase() |
FILE_DB_NAME |
path to asset of pre-populated data static var FILE_DB_NAME: String! |
instance |
singleton instance for database static var instance: GBDatabase! |
carParkDao |
abstract getter for Data accessing object abstract fun carParkDao(): CarParkDao! |
getInstance |
Getter method for Gym Buddy database if the room database is not existed, it creates from database file in assets folder open static fun getInstance(context: Context!): GBDatabase! |