Java Top

To help you get access to the material during the current, global COVID-19 crisis, all courses are 30% off until July 2

>> GET ACCESS NOW

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

To help you get access to the material during the current, global COVID-19 crisis, all courses are 30% off until July 2

>> GET ACCESS NOW

Comments are closed on this article!