Class TextUtil

java.lang.Object
com.atlassian.jira.util.TextUtil

public class TextUtil extends Object
You can never have enough StringUtils or TextUtils
  • Constructor Details

    • TextUtil

      public TextUtil()
  • Method Details

    • lpad

      @Nonnull public static String lpad(@Nonnull String original, int minLength)
      Pad the incoming String with spaces on the left to the given desired length.

      If the String is already of the minimum size or bigger, return it as is.

      Parameters:
      original - the String to pad
      minLength - the desired length
      Returns:
      A string padded with space to reach the desired minimum length
    • rpad

      @Nonnull public static String rpad(@Nonnull String original, int minLength)
      Pad the incoming String with spaces on the right to the given desired length.

      If the String is already of the minimum size or bigger, return it as is.

      Parameters:
      original - the String to pad
      minLength - the desired length
      Returns:
      A string padded with space to reach the desired minimum length