Lines Matching defs:migration
35 import androidx.room.migration.Migration;
448 * Adds a migration to the builder.
453 * If a migration item is missing between current version and the latest version, Room
457 * A migration can handle more than 1 version (e.g. if you have a faster path to choose when
459 * 3 and latest version is >= 5, Room will use the migration object that can migrate from
462 * @param migrations The migration object that can modify the database and to the necessary
471 for (Migration migration: migrations) {
472 mMigrationStartAndEndVersions.add(migration.startVersion);
473 mMigrationStartAndEndVersions.add(migration.endVersion);
560 * migration.
647 * same start-end versions, the latter migration overrides the previous one.
652 for (Migration migration : migrations) {
653 addMigration(migration);
657 private void addMigration(Migration migration) {
658 final int start = migration.startVersion;
659 final int end = migration.endVersion;
667 Log.w(Room.LOG_TAG, "Overriding migration " + existing + " with " + migration);
669 targetMap.append(end, migration);
679 * between the given versions. If a migration path cannot be found, returns {@code null}.