hasChildNodes( )
Provides a quick way to determine if a node has children. Returns true if the node has any children; otherwise, it returns false.
true
false
public boolean hasChildNodes( );