Class PropertyMigration<F extends com.cloudbees.hudson.plugins.folder.AbstractFolder<?>,P extends com.cloudbees.hudson.plugins.folder.AbstractFolderProperty<F>>

java.lang.Object
jenkins.branch.PropertyMigration<F,P>
Type Parameters:
F - the type of folder to which the migration is scoped.
P - the type of property to which the migration applies.
All Implemented Interfaces:
ExtensionPoint
Direct Known Subclasses:
NoTriggerOrganizationFolderProperty.PropertyMigrationImpl

public abstract class PropertyMigration<F extends com.cloudbees.hudson.plugins.folder.AbstractFolder<?>,P extends com.cloudbees.hudson.plugins.folder.AbstractFolderProperty<F>> extends Object implements ExtensionPoint
An extension point that captures the need for a complex migration of a folder property into some other configuration of the containing folder.
  • Constructor Details

    • PropertyMigration

      public PropertyMigration(Class<F> folderClass, Class<P> propertyClass, String pluginName)
  • Method Details

    • isApplicable

      public final boolean isApplicable(com.cloudbees.hudson.plugins.folder.AbstractFolder<?> folder)
    • canApply

      public final boolean canApply()
    • isEnabled

      protected boolean isEnabled()
      Whether this PropertyMigration is enabled. If it is enabled, and a corresponding PropertyMigration.Migrator extension is available, the migration will be applied automatically. If it is enabled, and no corresponding PropertyMigration.Migrator extension is available, then an admin monitor will be shown suggested that the user install or update a plugin that provides the migration. If it is disabled, then neither of these things will happen.
      Returns:
      true if this PropertyMigration is enabled, false if it is disabled.
    • getPluginName

      public final String getPluginName()
    • getPluginDisplayName

      public final String getPluginDisplayName()
    • getPluginInstallId

      public final String getPluginInstallId()
    • getPluginVersion

      public final String getPluginVersion()
    • isPendingRestart

      public final boolean isPendingRestart()
    • isPluginUpgrade

      public final boolean isPluginUpgrade()
    • getDescription

      public abstract org.jvnet.localizer.Localizable getDescription()
    • apply

      public final void apply(com.cloudbees.hudson.plugins.folder.AbstractFolder<?> folder)
    • equals

      public final boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public final int hashCode()
      Overrides:
      hashCode in class Object
    • applyAll

      public static void applyAll(com.cloudbees.hudson.plugins.folder.AbstractFolder<?> folder)