src/main/java/com/cloudbees/jenkins/support/util/StreamUtils.java
public static boolean isNonWhitespaceControlCharacter(@NonNull ByteBuffer head) {
        boolean hasControlCharacter = false;

        while (head.hasRemaining()) {
            hasControlCharacter |= isNonWhitespaceControlCharacter(head.get());
        }

        return hasControlCharacter;
    }
/**
     * Check if the content of a ByteBuffer is binary
     * @param head ByteBuffer to check
     * @return true if the content is binary (Non-white Control Characters)
     */
Check if the content of a ByteBuffer is binary
@param head ByteBuffer to check
@return true if the content is binary (Non-white Control Characters)
Check if the content of a ByteBuffer is binary @param head ByteBuffer to check @return true if the content is binary ( Non - white Control Characters )
public static boolean isNonWhitespaceControlCharacter(@NonNull ByteBuffer head) {
        boolean hasControlCharacter = false;
        while (head.hasRemaining()) {
            hasControlCharacter |= isNonWhitespaceControlCharacter(head.get());
        }
        return hasControlCharacter;
    }
public static boolean isNonWhitespaceControlCharacter ( @ NonNull ByteBuffer head ) { boolean hasControlCharacter = false ; while ( head . hasRemaining ( ) ) { hasControlCharacter |= isNonWhitespaceControlCharacter ( head . get ( ) ) ; } return hasControlCharacter ; }
Check if the content of a ByteBuffer is binary
 @param head ByteBuffer to check
 @return true if the content is binary (Non-white Control Characters)
Check if the content of a ByteBuffer is binary @param head ByteBuffer to check @return true if the content is binary ( Non - white Control Characters )