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

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

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

import java.util.Optional;
import org.apache.commons.lang3.StringUtils;
import tech.jhipster.lite.shared.error.domain.Assert;

public record JavaDependencyClassifier(String classifier) {
  public JavaDependencyClassifier {
    Assert.notBlank("classifier", classifier);
  }

  public static Optional of(String classifier) {
    return Optional.ofNullable(classifier).filter(StringUtils::isNotBlank).map(JavaDependencyClassifier::new);
  }

  public String get() {
    return classifier();
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy