|
![]() |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.AbstractAction
com.lowagie.rups.io.FileChooserAction
public class FileChooserAction
Allows you to browse the file system and forwards the file to the object that is waiting for you to choose a file.
Field Summary | |
---|---|
protected File |
file
The file that was chosen. |
protected FileFilter |
filter
A file filter to apply when browsing for a file. |
protected boolean |
newFile
Indicates if you're browsing to create a new or an existing file. |
protected Observable |
observable
An object that is expecting the result of the file chooser action. |
private static long |
serialVersionUID
A serial version UID. |
Fields inherited from class javax.swing.AbstractAction |
---|
changeSupport, enabled |
Fields inherited from interface javax.swing.Action |
---|
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON |
Constructor Summary | |
---|---|
FileChooserAction(Observable observable,
String caption,
FileFilter filter,
boolean newFile)
Creates a new file chooser action. |
Method Summary | |
---|---|
void |
actionPerformed(ActionEvent evt)
|
File |
getFile()
Getter for the file. |
Methods inherited from class javax.swing.AbstractAction |
---|
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected Observable observable
protected FileFilter filter
protected boolean newFile
protected File file
private static final long serialVersionUID
Constructor Detail |
---|
public FileChooserAction(Observable observable, String caption, FileFilter filter, boolean newFile)
observable
- the object waiting for you to select filecaption
- a description for the actionfilter
- a filter to apply when browsingnewFile
- indicates if you should browse for a new or existing fileMethod Detail |
---|
public File getFile()
public void actionPerformed(ActionEvent evt)
ActionListener.actionPerformed(java.awt.event.ActionEvent)
|
Hosted by Hostbasket | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |