All Downloads are FREE. Search and download functionalities are using the official Maven repository.

tech.jhipster.lite.module.domain.javadependency.UnknownJavaVersionSlugException Maven / Gradle / Ivy

There is a newer version: 1.22.0
Show newest version
package tech.jhipster.lite.module.domain.javadependency;

import tech.jhipster.lite.module.domain.javabuild.VersionSlug;
import tech.jhipster.lite.shared.error.domain.GeneratorException;

class UnknownJavaVersionSlugException extends GeneratorException {

  public UnknownJavaVersionSlugException(VersionSlug slug) {
    super(
      internalServerError(JavaDependencyErrorKey.UNKNOWN_VERSION)
        .message(buildMessage(slug))
        .addParameter("versionSlug", slug.propertyName())
    );
  }

  private static String buildMessage(VersionSlug slug) {
    return new StringBuilder()
      .append("Can't find property ")
      .append(slug.propertyName())
      .append(", forgot to add it in \"src/main/resources/generator/dependencies/pom.xml\"?")
      .toString();
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy