Java Top

I just announced the new Learn Spring course, focused on the fundamentals of Spring 5 and Spring Boot 2:

>> CHECK OUT THE COURSE

The method isEmpty() is a convenience method that checks if the size of a String is equal to zero.

Available Signatures

public boolean isEmpty()

Example

@Test
public void whenCallIsEmpty_thenCorrect() {
    String s1 = "";
    
    assertTrue(s1.isEmpty());
}
Next »
Java String.lastIndexOf()
« Previous
Java String.intern()
Java bottom

I just announced the new Learn Spring course, focused on the fundamentals of Spring 5 and Spring Boot 2:

>> CHECK OUT THE COURSE