code: public static boolean toBoolean(@Nullable final String booleanStr, final boolean defaultValue) {
          return StringUtils.isNoneEmpty(booleanStr) ? toBoolean(booleanStr) : defaultValue;
      }
docs: If the string is null or empty string, it returns the defaultValue otherwise it returns the boolean value (see tooBoolean)
  
  @param booleanStr   the string to convert to boolean
  @param defaultValue the default value if the string is empty or null
  @return true if the booleanStr is 'true', false if it's 'false'
  @throws IllegalArgumentException if the booleanStr is not a valid boolean