197 lines
5.7 KiB
JSON

{
"formatVersion": 1,
"database": {
"version": 2,
"identityHash": "aa61f620c85042ab06d0a84872090e3a",
"entities": [
{
"tableName": "game",
"createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `name` TEXT NOT NULL, `game_code` TEXT NOT NULL, `game_checksum` TEXT)",
"fields": [
{
"fieldPath": "id",
"columnName": "id",
"affinity": "INTEGER",
"notNull": false
},
{
"fieldPath": "name",
"columnName": "name",
"affinity": "TEXT",
"notNull": true
},
{
"fieldPath": "gameCode",
"columnName": "game_code",
"affinity": "TEXT",
"notNull": true
},
{
"fieldPath": "gameChecksum",
"columnName": "game_checksum",
"affinity": "TEXT",
"notNull": false
}
],
"primaryKey": {
"columnNames": [
"id"
],
"autoGenerate": true
},
"indices": [
{
"name": "index_game_game_code",
"unique": false,
"columnNames": [
"game_code"
],
"orders": [],
"createSql": "CREATE INDEX IF NOT EXISTS `index_game_game_code` ON `${TABLE_NAME}` (`game_code`)"
},
{
"name": "index_game_game_checksum",
"unique": false,
"columnNames": [
"game_checksum"
],
"orders": [],
"createSql": "CREATE INDEX IF NOT EXISTS `index_game_game_checksum` ON `${TABLE_NAME}` (`game_checksum`)"
}
],
"foreignKeys": []
},
{
"tableName": "cheat_folder",
"createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `game_id` INTEGER NOT NULL, `name` TEXT NOT NULL, FOREIGN KEY(`game_id`) REFERENCES `game`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
"fields": [
{
"fieldPath": "id",
"columnName": "id",
"affinity": "INTEGER",
"notNull": false
},
{
"fieldPath": "gameId",
"columnName": "game_id",
"affinity": "INTEGER",
"notNull": true
},
{
"fieldPath": "name",
"columnName": "name",
"affinity": "TEXT",
"notNull": true
}
],
"primaryKey": {
"columnNames": [
"id"
],
"autoGenerate": true
},
"indices": [
{
"name": "index_cheat_folder_game_id",
"unique": false,
"columnNames": [
"game_id"
],
"orders": [],
"createSql": "CREATE INDEX IF NOT EXISTS `index_cheat_folder_game_id` ON `${TABLE_NAME}` (`game_id`)"
}
],
"foreignKeys": [
{
"table": "game",
"onDelete": "CASCADE",
"onUpdate": "NO ACTION",
"columns": [
"game_id"
],
"referencedColumns": [
"id"
]
}
]
},
{
"tableName": "cheat",
"createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `cheat_folder_id` INTEGER NOT NULL, `name` TEXT NOT NULL, `description` TEXT, `code` TEXT NOT NULL, `enabled` INTEGER NOT NULL, FOREIGN KEY(`cheat_folder_id`) REFERENCES `cheat_folder`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
"fields": [
{
"fieldPath": "id",
"columnName": "id",
"affinity": "INTEGER",
"notNull": false
},
{
"fieldPath": "cheatFolderId",
"columnName": "cheat_folder_id",
"affinity": "INTEGER",
"notNull": true
},
{
"fieldPath": "name",
"columnName": "name",
"affinity": "TEXT",
"notNull": true
},
{
"fieldPath": "description",
"columnName": "description",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "code",
"columnName": "code",
"affinity": "TEXT",
"notNull": true
},
{
"fieldPath": "enabled",
"columnName": "enabled",
"affinity": "INTEGER",
"notNull": true
}
],
"primaryKey": {
"columnNames": [
"id"
],
"autoGenerate": true
},
"indices": [
{
"name": "index_cheat_cheat_folder_id",
"unique": false,
"columnNames": [
"cheat_folder_id"
],
"orders": [],
"createSql": "CREATE INDEX IF NOT EXISTS `index_cheat_cheat_folder_id` ON `${TABLE_NAME}` (`cheat_folder_id`)"
}
],
"foreignKeys": [
{
"table": "cheat_folder",
"onDelete": "CASCADE",
"onUpdate": "NO ACTION",
"columns": [
"cheat_folder_id"
],
"referencedColumns": [
"id"
]
}
]
}
],
"views": [],
"setupQueries": [
"CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)",
"INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, 'aa61f620c85042ab06d0a84872090e3a')"
]
}
}