question: public static boolean isBlank ( String str ) { int strLen ; if ( str != null && ( strLen = str . length ( ) ) != 0 ) { for ( int i = 0 ; i < strLen ; i ++ ) { if ( ! Character . isWhitespace ( str . charAt ( i ) ) ) { return false ; } } } return true ; }
target:  Checks if a string is whitespace, empty ("") or null. Strings.isBlank(null)      = true Strings.isBlank("")        = true Strings.isBlank(" ")       = true Strings.isBlank("bob")     = false Strings.isBlank("  bob  ") = false