{ "formatVersion": 1, "database": { "version": 2, "identityHash": "48411ce0f1f22ef1dccd5852a9e97c5d", "entities": [ { "tableName": "groups", "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `name` TEXT NOT NULL, `faculty` TEXT NOT NULL, `autumnFirst` INTEGER, `autumnSecond` INTEGER, `springFirst` INTEGER, `springSecond` INTEGER, `lastSyncedAt` INTEGER NOT NULL, PRIMARY KEY(`id`))", "fields": [ { "fieldPath": "id", "columnName": "id", "affinity": "TEXT", "notNull": true }, { "fieldPath": "name", "columnName": "name", "affinity": "TEXT", "notNull": true }, { "fieldPath": "faculty", "columnName": "faculty", "affinity": "TEXT", "notNull": true }, { "fieldPath": "autumnFirst", "columnName": "autumnFirst", "affinity": "INTEGER" }, { "fieldPath": "autumnSecond", "columnName": "autumnSecond", "affinity": "INTEGER" }, { "fieldPath": "springFirst", "columnName": "springFirst", "affinity": "INTEGER" }, { "fieldPath": "springSecond", "columnName": "springSecond", "affinity": "INTEGER" }, { "fieldPath": "lastSyncedAt", "columnName": "lastSyncedAt", "affinity": "INTEGER", "notNull": true } ], "primaryKey": { "autoGenerate": false, "columnNames": [ "id" ] } }, { "tableName": "schedules", "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `groupId` TEXT NOT NULL, `season` TEXT NOT NULL, `weekStart` INTEGER NOT NULL, `weekEnd` INTEGER NOT NULL, `lastSyncedAt` INTEGER NOT NULL, FOREIGN KEY(`groupId`) REFERENCES `groups`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )", "fields": [ { "fieldPath": "id", "columnName": "id", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "groupId", "columnName": "groupId", "affinity": "TEXT", "notNull": true }, { "fieldPath": "season", "columnName": "season", "affinity": "TEXT", "notNull": true }, { "fieldPath": "weekStart", "columnName": "weekStart", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "weekEnd", "columnName": "weekEnd", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "lastSyncedAt", "columnName": "lastSyncedAt", "affinity": "INTEGER", "notNull": true } ], "primaryKey": { "autoGenerate": true, "columnNames": [ "id" ] }, "indices": [ { "name": "index_schedules_groupId", "unique": false, "columnNames": [ "groupId" ], "orders": [], "createSql": "CREATE INDEX IF NOT EXISTS `index_schedules_groupId` ON `${TABLE_NAME}` (`groupId`)" }, { "name": "index_schedules_groupId_season_weekStart", "unique": true, "columnNames": [ "groupId", "season", "weekStart" ], "orders": [], "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_schedules_groupId_season_weekStart` ON `${TABLE_NAME}` (`groupId`, `season`, `weekStart`)" } ], "foreignKeys": [ { "table": "groups", "onDelete": "CASCADE", "onUpdate": "NO ACTION", "columns": [ "groupId" ], "referencedColumns": [ "id" ] } ] }, { "tableName": "days", "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `scheduleId` INTEGER NOT NULL, `date` INTEGER NOT NULL, FOREIGN KEY(`scheduleId`) REFERENCES `schedules`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )", "fields": [ { "fieldPath": "id", "columnName": "id", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "scheduleId", "columnName": "scheduleId", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "date", "columnName": "date", "affinity": "INTEGER", "notNull": true } ], "primaryKey": { "autoGenerate": true, "columnNames": [ "id" ] }, "indices": [ { "name": "index_days_scheduleId", "unique": false, "columnNames": [ "scheduleId" ], "orders": [], "createSql": "CREATE INDEX IF NOT EXISTS `index_days_scheduleId` ON `${TABLE_NAME}` (`scheduleId`)" }, { "name": "index_days_date", "unique": false, "columnNames": [ "date" ], "orders": [], "createSql": "CREATE INDEX IF NOT EXISTS `index_days_date` ON `${TABLE_NAME}` (`date`)" } ], "foreignKeys": [ { "table": "schedules", "onDelete": "CASCADE", "onUpdate": "NO ACTION", "columns": [ "scheduleId" ], "referencedColumns": [ "id" ] } ] }, { "tableName": "lessons", "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `dayId` INTEGER NOT NULL, `date` INTEGER NOT NULL, `slotIndex` INTEGER NOT NULL, `start` INTEGER NOT NULL, `end` INTEGER NOT NULL, `lessonIndex` INTEGER NOT NULL, `raw` TEXT NOT NULL, `room` TEXT, `groupName` TEXT, `subgroup` TEXT, `subject` TEXT, `type` TEXT NOT NULL, `teacher` TEXT, FOREIGN KEY(`dayId`) REFERENCES `days`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )", "fields": [ { "fieldPath": "id", "columnName": "id", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "dayId", "columnName": "dayId", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "date", "columnName": "date", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "slotIndex", "columnName": "slotIndex", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "start", "columnName": "start", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "end", "columnName": "end", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "lessonIndex", "columnName": "lessonIndex", "affinity": "INTEGER", "notNull": true }, { "fieldPath": "raw", "columnName": "raw", "affinity": "TEXT", "notNull": true }, { "fieldPath": "room", "columnName": "room", "affinity": "TEXT" }, { "fieldPath": "groupName", "columnName": "groupName", "affinity": "TEXT" }, { "fieldPath": "subgroup", "columnName": "subgroup", "affinity": "TEXT" }, { "fieldPath": "subject", "columnName": "subject", "affinity": "TEXT" }, { "fieldPath": "type", "columnName": "type", "affinity": "TEXT", "notNull": true }, { "fieldPath": "teacher", "columnName": "teacher", "affinity": "TEXT" } ], "primaryKey": { "autoGenerate": true, "columnNames": [ "id" ] }, "indices": [ { "name": "index_lessons_dayId", "unique": false, "columnNames": [ "dayId" ], "orders": [], "createSql": "CREATE INDEX IF NOT EXISTS `index_lessons_dayId` ON `${TABLE_NAME}` (`dayId`)" }, { "name": "index_lessons_date", "unique": false, "columnNames": [ "date" ], "orders": [], "createSql": "CREATE INDEX IF NOT EXISTS `index_lessons_date` ON `${TABLE_NAME}` (`date`)" }, { "name": "index_lessons_subject", "unique": false, "columnNames": [ "subject" ], "orders": [], "createSql": "CREATE INDEX IF NOT EXISTS `index_lessons_subject` ON `${TABLE_NAME}` (`subject`)" }, { "name": "index_lessons_room", "unique": false, "columnNames": [ "room" ], "orders": [], "createSql": "CREATE INDEX IF NOT EXISTS `index_lessons_room` ON `${TABLE_NAME}` (`room`)" } ], "foreignKeys": [ { "table": "days", "onDelete": "CASCADE", "onUpdate": "NO ACTION", "columns": [ "dayId" ], "referencedColumns": [ "id" ] } ] }, { "tableName": "preferences", "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`key` TEXT NOT NULL, `value` TEXT NOT NULL, PRIMARY KEY(`key`))", "fields": [ { "fieldPath": "key", "columnName": "key", "affinity": "TEXT", "notNull": true }, { "fieldPath": "value", "columnName": "value", "affinity": "TEXT", "notNull": true } ], "primaryKey": { "autoGenerate": false, "columnNames": [ "key" ] } } ], "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, '48411ce0f1f22ef1dccd5852a9e97c5d')" ] } }