Class DotNetSDK.DescriptorImpl

All Implemented Interfaces:
PersistentDescriptor, Saveable, OnMaster
Enclosing class:
DotNetSDK

@Extension @Symbol("dotnetsdk") public static class DotNetSDK.DescriptorImpl extends ToolDescriptor<DotNetSDK> implements PersistentDescriptor
A descriptor for .NET SDK installations.
  • Constructor Details

    • DescriptorImpl

      public DescriptorImpl()
  • Method Details

    • checkHomeDirectory

      @NonNull protected FormValidation checkHomeDirectory(@NonNull File home)
      Performs validation on the installation directory for a .NET SDK.
      Overrides:
      checkHomeDirectory in class ToolDescriptor<DotNetSDK>
      Parameters:
      home - The directory to validate.
      Returns:
      The validation result.
    • getDefaultInstallers

      @NonNull public List<? extends ToolInstaller> getDefaultInstallers()
      Gets the default installer to use for a .NET SDK installation.
      Overrides:
      getDefaultInstallers in class ToolDescriptor<DotNetSDK>
      Returns:
      A list containing a single DotNetSDKInstaller instance.
    • getDisplayName

      @NonNull public String getDisplayName()
      Returns the display name for .NET SDK installations.
      Overrides:
      getDisplayName in class Descriptor<ToolInstallation>
      Returns:
      ".NET SDK" or a localized equivalent.
    • prepareAndValidateInstance

      @NonNull public DotNetSDK prepareAndValidateInstance(@NonNull String name, @NonNull FilePath workspace, @NonNull EnvVars env, @NonNull TaskListener listener) throws IOException, InterruptedException
      Gets a .NET SDK installation by its name, and prepare it for use in the specified context.
      Parameters:
      name - The name of the configured .NET SDK installation.
      workspace - The workspace to use.
      env - The environment to use.
      listener - The task listener to use.
      Returns:
      The requested .NET SDK installation.
      Throws:
      AbortException - When the SDK installation could not be set up.
      IOException - Then an I/O error occurs.
      InterruptedException - When processing is interrupted.
    • setInstallations

      public void setInstallations(@NonNull DotNetSDK... sdks)
      Sets the set of configured .NET SDK installations.
      Overrides:
      setInstallations in class ToolDescriptor<DotNetSDK>
      Parameters:
      sdks - The set of configured .NET SDK installations.