Interface SettingsBuilder

All Superinterfaces:
Service

@Experimental public interface SettingsBuilder extends Service
Builds the effective settings from a user settings file and/or an installation settings file.
Since:
4.0.0
  • Method Details

    • build

      @Nonnull SettingsBuilderResult build(@Nonnull SettingsBuilderRequest request)
      Builds the effective settings of the specified settings files.
      Parameters:
      request - the settings building request that holds the parameters, must not be null
      Returns:
      the result of the settings building, never null
      Throws:
      SettingsBuilderException - if the effective settings could not be built
    • build

      @Nonnull default SettingsBuilderResult build(@Nonnull Session session, @Nonnull Source installationSettingsSource, @Nonnull Source userSettingsSource)
      Builds the effective settings of the specified settings sources.
      Returns:
      the result of the settings building, never null
      Throws:
      SettingsBuilderException - if the effective settings could not be built
    • build

      @Nonnull default SettingsBuilderResult build(@Nonnull Session session, @Nonnull Path installationSettingsPath, @Nonnull Path userSettingsPath)
      Builds the effective settings of the specified settings paths.
      Returns:
      the result of the settings building, never null
      Throws:
      SettingsBuilderException - if the effective settings could not be built
    • build

      @Nonnull default SettingsBuilderResult build(@Nonnull Session session, @Nonnull Source installationSettingsSource, @Nonnull Source projectSettingsSource, @Nonnull Source userSettingsSource)
      Builds the effective settings of the specified settings sources.
      Returns:
      the result of the settings building, never null
      Throws:
      SettingsBuilderException - if the effective settings could not be built
    • build

      @Nonnull default SettingsBuilderResult build(@Nonnull Session session, @Nonnull Path installationSettingsPath, @Nonnull Path projectSettingsPath, @Nonnull Path userSettingsPath)
      Builds the effective settings of the specified settings paths.
      Returns:
      the result of the settings building, never null
      Throws:
      SettingsBuilderException - if the effective settings could not be built
    • validate

      @Nonnull default ProblemCollector<BuilderProblem> validate(@Nonnull org.apache.maven.api.settings.Settings settings)
      Validate the specified settings.
      Parameters:
      settings - The settings to validate, must not be null.
      Returns:
      The list of problems that were encountered, must not be null.
    • validate

      @Nonnull ProblemCollector<BuilderProblem> validate(@Nonnull org.apache.maven.api.settings.Settings settings, boolean isProjectSettings)
      Validate the specified settings.
      Parameters:
      settings - The settings to validate, must not be null.
      isProjectSettings - Boolean indicating if the validation is for project settings or user / installation settings.
      Returns:
      The list of problems that were encountered, must not be null.
    • convert

      @Nonnull org.apache.maven.api.settings.Profile convert(@Nonnull org.apache.maven.api.model.Profile profile)
      Convert a model profile to a settings profile.
    • convert

      @Nonnull org.apache.maven.api.model.Profile convert(@Nonnull org.apache.maven.api.settings.Profile profile)
      Convert a settings profile to a model profile.