tomaswolf commented on a change in pull request #196:
URL: https://github.com/apache/mina-sshd/pull/196#discussion_r641974333



##########
File path: 
sshd-common/src/main/java/org/apache/sshd/common/util/GenericUtils.java
##########
@@ -196,6 +196,49 @@ public static boolean isNotEmpty(CharSequence cs) {
         return !isEmpty(cs);
     }
 
+    /**
+     * <p>
+     * Checks if a CharSequence is empty (""), null or whitespace only.
+     * </p>
+     *
+     * <p>
+     * Whitespace is defined by {@link Character#isWhitespace(char)}.
+     * </p>
+     *
+     * <pre>
+     * StringUtils.isBlank(null)      = true
+     * StringUtils.isBlank("")        = true
+     * StringUtils.isBlank(" ")       = true
+     * StringUtils.isBlank("bob")     = false
+     * StringUtils.isBlank("  bob  ") = false
+     * </pre>
+     *
+     * @param  cs the CharSequence to check, may be null
+     * @return    {@code true} if the CharSequence is null, empty or 
whitespace only
+     * @since     2.0
+     * @since     3.0 Changed signature from isBlank(String) to 
isBlank(CharSequence)

Review comment:
       So this was copied from somewhere. Looks like StringUtils from 
org.apache.commons.lang, so license-wise OK.
   
   I'll remove the misleading "since" tags and fix the comment.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to