org.openide.filesystems
Interface FileChooserBuilder.SelectionApprover
- Enclosing class:
- FileChooserBuilder
public static interface FileChooserBuilder.SelectionApprover
Object which can approve the selection (enabling the OK button or
equivalent) in a JFileChooser. Equivalent to overriding
JFileChooser.approveSelection()
- Since:
- 7.26.0
Method Summary |
boolean |
approve(File[] selection)
Approve the selection, enabling the dialog to be closed. |
approve
boolean approve(File[] selection)
- Approve the selection, enabling the dialog to be closed. Called by
the JFileChooser's
approveSelection()
method. Use this
interface if you want to, for example, show a dialog asking
"Overwrite File X?" or similar.
- Parameters:
selection
- The selected file(s) at the time the user presses
the Open, Save or OK button
- Returns:
- true if the selection is accepted, false if it is not and
the dialog should not be closed