java.lang.Object
com.sk89q.worldguard.protection.managers.migration.UUIDMigration
All Implemented Interfaces:
Migration

public class UUIDMigration extends Object
Migrates names to UUIDs for all the worlds in a region store.
  • Constructor Details

    • UUIDMigration

      public UUIDMigration(RegionDriver driver, com.sk89q.worldguard.util.profile.resolver.ProfileService profileService, FlagRegistry flagRegistry)
      Create a new instance.
      Parameters:
      driver - the storage driver
      profileService - the profile service
      flagRegistry - the flag registry
  • Method Details

    • migrate

      protected void migrate(RegionDatabase store) throws MigrationException
      Called for all the worlds in the driver.
      Parameters:
      store - the region store
      Throws:
      MigrationException - on migration error
    • postMigration

      protected void postMigration()
      Called after migration has successfully completed.
    • getKeepUnresolvedNames

      public boolean getKeepUnresolvedNames()
      Get whether names that have no UUID equivalent (i.e. name that is not owned) should be kept as names and not removed.
      Returns:
      true to keep names
    • setKeepUnresolvedNames

      public void setKeepUnresolvedNames(boolean keepUnresolvedNames)
      Set whether names that have no UUID equivalent (i.e. name that is not owned) should be kept as names and not removed.
      Parameters:
      keepUnresolvedNames - true to keep names
    • migrate

      public final void migrate() throws MigrationException
      Description copied from interface: Migration
      Execute the migration.
      Specified by:
      migrate in interface Migration
      Throws:
      MigrationException - thrown if the migration fails