dsto.dfc.swing.persistence
Class BasicDocumentSaveCommand
java.lang.Object
dsto.dfc.swing.commands.AbstractCommand
dsto.dfc.swing.commands.AbstractMutableCommand
dsto.dfc.swing.commands.BasicFileSaveCommand
dsto.dfc.swing.persistence.BasicDocumentSaveCommand
- All Implemented Interfaces:
- Command, Iconic, Copyable, PropertyEventSource, ActionListener, PropertyChangeListener, Cloneable, EventListener
public class BasicDocumentSaveCommand
- extends BasicFileSaveCommand
- implements PropertyChangeListener
Command to invoke the save () method on a Document
. This
command is only enabled then the document has been changed (Document.isChanged()
.
- Version:
- $Revision$
- Author:
- Matthew Phillips
BasicDocumentSaveCommand
public BasicDocumentSaveCommand(Document document)
execute
public void execute()
- Description copied from class:
BasicFileSaveCommand
- Provides a basic implementation: pops up a file chooser and calls
either saveFile () or dialogCancelled ().
- Specified by:
execute
in interface Command
- Overrides:
execute
in class BasicFileSaveCommand
- See Also:
BasicFileSaveCommand.initFileChooser(javax.swing.JFileChooser)
,
BasicFileSaveCommand.saveFile(javax.swing.JFileChooser)
,
BasicFileSaveCommand.dialogCancelled(javax.swing.JFileChooser)
getDescription
public String getDescription()
- Description copied from interface:
Command
- A short description of the command, suitable for a tooltip or use
in a status panel.
- Specified by:
getDescription
in interface Command
- Overrides:
getDescription
in class BasicFileSaveCommand
propertyChange
public void propertyChange(PropertyChangeEvent e)
- Specified by:
propertyChange
in interface PropertyChangeListener
Copyright © 2008 Commonwealth of Australia