| org.jfree.ui.action.AbstractActionDowngrade org.jfree.ui.action.AbstractFileSelectionAction
AbstractFileSelectionAction | abstract public class AbstractFileSelectionAction extends AbstractActionDowngrade (Code) | | A base class for all file operations. This implementation provides all methods
to let the user select a file.
author: Thomas Morgner |
Constructor Summary | |
public | AbstractFileSelectionAction(Component parent) Creates a new FileSelectionAction with the given optional parent component
as parent for the file chooser dialog. |
Method Summary | |
protected JFileChooser | createFileChooser() Creates the file chooser. | protected File | getCurrentDirectory() Returns the working directory that should be used when initializing
the FileChooser. | abstract protected String | getFileDescription() Returns a descriptive text describing the file extension. | abstract protected String | getFileExtension() Returns the file extension that should be used for the operation. | protected File | performSelectFile(File selectedFile, int dialogType, boolean appendExtension) Selects a file to use as target for the operation.
Parameters: selectedFile - the selected file. Parameters: dialogType - the dialog type. Parameters: appendExtension - true, if the file extension should be added ifnecessary, false if the unmodified filename should be used. |
AbstractFileSelectionAction | public AbstractFileSelectionAction(Component parent)(Code) | | Creates a new FileSelectionAction with the given optional parent component
as parent for the file chooser dialog.
Parameters: parent - the parent |
createFileChooser | protected JFileChooser createFileChooser()(Code) | | Creates the file chooser.
the initialized file chooser. |
getCurrentDirectory | protected File getCurrentDirectory()(Code) | | Returns the working directory that should be used when initializing
the FileChooser.
the working directory. |
getFileDescription | abstract protected String getFileDescription()(Code) | | Returns a descriptive text describing the file extension.
the file description. |
getFileExtension | abstract protected String getFileExtension()(Code) | | Returns the file extension that should be used for the operation.
the file extension. |
performSelectFile | protected File performSelectFile(File selectedFile, int dialogType, boolean appendExtension)(Code) | | Selects a file to use as target for the operation.
Parameters: selectedFile - the selected file. Parameters: dialogType - the dialog type. Parameters: appendExtension - true, if the file extension should be added ifnecessary, false if the unmodified filename should be used. the selected and approved file or null, if the user canceledthe operation |
|
|