Class IncubatingApplicationModelResolver

java.lang.Object
io.quarkus.bootstrap.resolver.maven.IncubatingApplicationModelResolver

public class IncubatingApplicationModelResolver extends Object
  • Constructor Details

    • IncubatingApplicationModelResolver

      public IncubatingApplicationModelResolver()
  • Method Details

    • isIncubatingEnabled

      public static boolean isIncubatingEnabled(Properties projectProperties)
      Temporary method that will be removed once this implementation becomes the default.

      Returns true if system or POM property quarkus.bootstrap.incubating-model-resolver is set to true.

      Returns:
      true if this implementation is enabled
    • isIncubatingModelResolverProperty

      public static boolean isIncubatingModelResolverProperty(Properties projectProperties, String value)
      Temporary method that will be removed once this implementation becomes the default.

      Calls getIncubatingModelResolverProperty(Properties) and checks whether the returned value equals the passed in value.

      Returns:
      true if value of quarkus.bootstrap.incubating-model-resolver property is equal to the passed in value
    • getIncubatingModelResolverProperty

      public static String getIncubatingModelResolverProperty(Properties projectProperties)
      Temporary method that will be removed once this implementation becomes the default.

      Returns value of system or POM property quarkus.bootstrap.incubating-model-resolver. The system property is checked first and if its value is not null, it's returned. Otherwise, the value of POM property is returned as the result.

      Returns:
      value of system or POM property quarkus.bootstrap.incubating-model-resolver or null if it's not set
    • newInstance

      public static IncubatingApplicationModelResolver newInstance()
    • setArtifactResolver

      public IncubatingApplicationModelResolver setArtifactResolver(MavenArtifactResolver resolver)
      Maven artifact resolver that should be used to resolve application dependencies
      Parameters:
      resolver - Maven artifact resolver
      Returns:
      self
    • setApplicationModelBuilder

      public IncubatingApplicationModelResolver setApplicationModelBuilder(ApplicationModelBuilder appBuilder)
      Application model builder to add the resolved dependencies to.
      Parameters:
      appBuilder - application model builder
      Returns:
      self
    • setCollectReloadableModules

      public IncubatingApplicationModelResolver setCollectReloadableModules(boolean collectReloadableModules)
      Whether to indicate which resolved dependencies are reloadable.
      Parameters:
      collectReloadableModules - whether indicate which resolved dependencies are reloadable
      Returns:
      self
    • setDependencyLogging

      public IncubatingApplicationModelResolver setDependencyLogging(DependencyLoggingConfig depLogging)
      Dependency logging configuration. For example to log the resolved dependency tree.
      Parameters:
      depLogging - dependency logging configuration
      Returns:
      self
    • setCollectCompileOnly

      public IncubatingApplicationModelResolver setCollectCompileOnly(List<org.eclipse.aether.graph.Dependency> collectCompileOnly)
      In addition to resolving dependencies for the build classpath, also resolve these compile-only dependencies and add them to the application model as DependencyFlags.COMPILE_ONLY.
      Parameters:
      collectCompileOnly - compile-only dependencies to add to the model
      Returns:
      self
    • setRuntimeModelOnly

      public IncubatingApplicationModelResolver setRuntimeModelOnly(boolean runtimeModelOnly)
      Whether to limit the resulting ApplicationModel to the runtime dependencies.
      Parameters:
      runtimeModelOnly - whether to limit the resulting application model to the runtime dependencies
      Returns:
      self
    • setDevMode

      public IncubatingApplicationModelResolver setDevMode(boolean devMode)
      Whether an application model is resolved for dev mode
      Parameters:
      devMode - whether an application model is resolved for dev mode
      Returns:
      self
    • resolve

      public void resolve(org.eclipse.aether.collection.CollectRequest collectRtDepsRequest) throws AppModelResolverException
      Resolves application dependencies and adds the to the application model builder.
      Parameters:
      collectRtDepsRequest - request to collect runtime dependencies
      Throws:
      AppModelResolverException - in case of a failure