Package backupmanager.action
Class BackupAction
java.lang.Object
backupmanager.action.BackupAction
- All Implemented Interfaces:
 BackupFunction
- Direct Known Subclasses:
 CopyFile,DeleteFile
- 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionabstract booleandoAction(BackupManager backupManager, BackupStream backupStream, StreamItem streamItem) Perform a backup action.abstract PamDialogPanelgetDialogPanel(Window owner) Get a dialog panel for this action to incorporate into a larger dialog.abstract StringgetName()abstract ActionSettingsGet settings associated with this action.getSpace()abstract booleanflag to say whether or not to run this action if any previous action threw an error.voidsetBackupFilter(BackupFilter backupFilter) abstract booleansetSettings(ActionSettings settings) Set settings.booleanshowDialog(Window owner)  
- 
Constructor Details
- 
BackupAction
 
 - 
 - 
Method Details
- 
doAction
public abstract boolean doAction(BackupManager backupManager, BackupStream backupStream, StreamItem streamItem) throws BackupException Perform a backup action. Return false or throw an exception if the action fails.- Parameters:
 backupManager-streamItem-streamInformation-- Returns:
 - Throws:
 BackupException
 - 
getSettings
Get settings associated with this action.
All actions must return settings even if they have nothing in them, since the settings are needed to recreate the action based on it's class name.- Returns:
 - action settings
 
 - 
setSettings
Set settings. Will return false if they were the wrong type for this action - though that should not be possible.- Parameters:
 settings-- Returns:
 - true if settings are OK.
 
 - 
showDialog
- Returns:
 - a dialog panel for controlling any of the settings.
 
 - 
runIfPreviousActionError
public abstract boolean runIfPreviousActionError()flag to say whether or not to run this action if any previous action threw an error. Actions such as a file copy would probably want to run anyway, since may be copying to different disks and if one is full, you'd want to copy to the other. But if you'd failed to copy a file to a backup drive, you probably wouldn't want to delete it!- Returns:
 - true if it's OK to run this action when a previous action failed.
 
 - 
getDialogPanel
Get a dialog panel for this action to incorporate into a larger dialog.- Specified by:
 getDialogPanelin interfaceBackupFunction- Parameters:
 owner-- Returns:
 - dialog panel (assuming most actions have one - can return null).
 
 - 
getName
- Specified by:
 getNamein interfaceBackupFunction- Returns:
 - a name for the action, to display in dialogs
 
 - 
getBackupStream
- Returns:
 - the backupStream
 
 - 
getActionMaker
- Returns:
 - the actionMaker
 
 - 
getBackupFilter
 - 
setBackupFilter
 - 
getSpace
 
 -