Since the majority of applications nowadays have GUI interfaces, it would be nice
to provide such an interface for our file handling programs. The reader will almost
certainly have used file handling applications that provide such an interface. A particularly
common feature of such applications is the provision of a dialogue box that
allows the user to navigate the computer’s file system and select either an existing
file for opening or the destination directory for a file that is to be created. By employing
Swing class JFileChooser , we can display a dialogue box that will allow the
user to do just that.