I would like to know the difference between showOpenDialog()
and showSaveDialog()
methods in the JFileChooser
.
What I found is the change in the title and the text of the approve button. Nothing seemed to be a difference. They can be set by using setDialogTitle()
and setApproveButtonText()
respectively. But what is the reason behind the existence of two of these methods when they can be carried out normally.
Please don't answer about the difference between open and save. Rather, I would like to know the reason behind those two methods. Also don't answer You ask the swing team or any other similar answer.
They seem to be internally using showDialog()
, I can use it because it is public
. And for both dialogs I am able to get the selected file(s).
I feel there is no difference. I would like to here opinions of others.