类 StringHelper

java.lang.Object
com.github.codeboyzhou.mcp.declarative.util.StringHelper

public final class StringHelper extends Object
Helper class for string operations.
作者:
codeboyzhou
  • 字段详细资料

  • 方法详细资料

    • isBlank

      public static boolean isBlank(String str)
      Checks if the given string is blank.
      参数:
      str - the string to check
      返回:
      true if the string is blank, false otherwise
    • defaultIfBlank

      public static String defaultIfBlank(String str, String defaultValue)
      Returns the default value if the given string is blank, otherwise returns the original string.
      参数:
      str - the string to check
      defaultValue - the default value to return if the string is blank
      返回:
      the original string if it is not blank, otherwise the default value