public class FileChooserModel extends Object
| Constructor and Description |
|---|
FileChooserModel() |
| Modifier and Type | Method and Description |
|---|---|
void |
addPropertyChangeListener(PropertyChangeListener listener)
Add a property change listener.
|
void |
addPropertyChangeListener(String propertyName,
PropertyChangeListener listener)
Add a property change listener for a named property.
|
File |
getCurrentDirectory()
Retrieves the current directory to open in the chooser.
|
String[] |
getExtensions()
Retrieves the file extensions used by the file chooser.
|
File |
getFile()
Retrieves the file selected by the user.
|
boolean |
getShowDialog()
Retrieves the show dialog flag.
|
void |
removePropertyChangeListener(PropertyChangeListener listener)
Remove a property change listener.
|
void |
setCurrentDirectory(File value)
Sets the current directory to open in the chooser.
|
void |
setExtensions(String... extensions)
Sets the file extensions used by the file chooser.
|
void |
setFile(File file)
Sets the file selected by the user.
|
void |
setShowDialog(boolean showDialog)
Sets the show dialog flag.
|
public boolean getShowDialog()
public void setShowDialog(boolean showDialog)
showDialog - show dialog flagpublic File getFile()
public void setFile(File file)
file - file selected by the user.public String[] getExtensions()
public void setExtensions(String... extensions)
extensions - file extensionspublic File getCurrentDirectory()
public void setCurrentDirectory(File value)
value - current directorypublic void addPropertyChangeListener(PropertyChangeListener listener)
listener - property change listenerpublic void addPropertyChangeListener(String propertyName, PropertyChangeListener listener)
propertyName - property namelistener - listenerpublic void removePropertyChangeListener(PropertyChangeListener listener)
listener - property change listenerCopyright © 2000–2025 MPXJ. All rights reserved.