I'm using JTree to display the contents of the selected directory recursively. Now when an empty directory is present on the filesystem, it is displayed as a leaf node as it does not have any child.
How do I use the parent node icon for empty directories?