Class ImporterUtils


  • public final class ImporterUtils
    extends java.lang.Object
    Utility validation methods for importing Bamboo Specs.

    Methods from this class prefixed with check throw exceptions on failures. For validation utility methods which return validation problems instead of throwing, use ValidationUtils.

    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void checkArgument​(@NotNull ValidationContext validationContext, boolean expression, java.lang.Object errorMessage)  
      static void checkNoErrors​(@NotNull java.util.List<ValidationProblem> errors)  
      static void checkNoErrors​(@NotNull java.util.Optional<ValidationProblem> error)  
      static java.lang.String checkNotBlank​(@NotNull ValidationContext validationContext, @NotNull java.lang.String argumentName, @Nullable java.lang.String o)
      Used to extra validate argument that shouldn't be blank.
      static java.lang.String checkNotBlank​(@NotNull java.lang.String argumentName, @Nullable java.lang.String o)
      Used to extra validate argument that shouldn't be blank.
      static java.lang.String checkNotEmpty​(@NotNull ValidationContext validationContext, @NotNull java.lang.String argumentName, @Nullable java.lang.String s)  
      static java.lang.String checkNotEmpty​(@NotNull java.lang.String argumentName, @Nullable java.lang.String s)  
      static void checkNotNegative​(@NotNull ValidationContext validationContext, @NotNull java.lang.String argumentName, int value)
      Used during building properties to check that a number is a non-negative integer.
      static void checkNotNegative​(@NotNull java.lang.String argumentName, int value)
      Used during building properties to check that a number is a non-negative integer.
      static <T> T checkNotNull​(@NotNull ValidationContext validationContext, @NotNull java.lang.String argumentName, T o)
      Used to extra validate argument that shouldn't be null to throw our exception instead of NPE.
      static <T> T checkNotNull​(@NotNull java.lang.String argumentName, T o)
      Used to extra validate argument that shouldn't be null to throw our exception instead of NPE.
      static void checkPluginKey​(@NotNull ValidationContext validationContext, @NotNull AtlassianModuleProperties actual, @NotNull AtlassianModuleProperties expected)  
      static void checkPositive​(@NotNull ValidationContext validationContext, @NotNull java.lang.String argumentName, int value)
      Used during building properties to check that a number is a positive integer.
      static void checkPositive​(@NotNull ValidationContext validationContext, @NotNull java.lang.String argumentName, long value)
      Used during building properties to check that a number is a positive integer.
      static void checkPositive​(@NotNull java.lang.String argumentName, int value)
      Used during building properties to check that a number is a positive integer.
      static void checkPositive​(@NotNull java.lang.String argumentName, long value)
      Used during building properties to check that a number is a positive integer.
      static void checkRequired​(@NotNull ValidationContext validationContext, @NotNull java.lang.String propertyName, @Nullable java.lang.Object o)
      Used during building properties object when some property is missing.
      static void checkRequired​(@NotNull ValidationContext validationContext, @Nullable java.lang.Object o)
      Used during building properties object when some property is missing.
      static void checkRequiredNotBlank​(@NotNull ValidationContext validationContext, @Nullable java.lang.String s)
      Used during building properties object when some property is missing.
      static void checkThat​(@NotNull ValidationContext validationContext, boolean condition, @NotNull java.lang.String messageFormat, @NotNull java.lang.Object... messageArgs)  
      static void checkThat​(@NotNull java.lang.String message, @org.jetbrains.annotations.NotNull boolean condition)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait