Class StringUtils

java.lang.Object
io.micrometer.tracing.util.StringUtils

public final class StringUtils extends Object
Utilities for String.
  • Method Details

    • isBlank

      public static boolean isBlank(@Nullable String string)
      Check if the String is null or has only whitespaces. Modified from org.apache.commons.lang.StringUtils#isBlank(String).
      Parameters:
      string - String to check
      Returns:
      true if the String is null or has only whitespaces
    • isNotBlank

      public static boolean isNotBlank(@Nullable String string)
      Check if the String has any non-whitespace character.
      Parameters:
      string - String to check
      Returns:
      true if the String has any non-whitespace character
    • isEmpty

      public static boolean isEmpty(@Nullable String string)
      Check if the String is null or empty.
      Parameters:
      string - String to check
      Returns:
      true if the String is null or empty
    • isNotEmpty

      public static boolean isNotEmpty(@Nullable String string)
      Check if the String has any character.
      Parameters:
      string - String to check
      Returns:
      true if the String has any character
      Since:
      1.1.0