public abstract class AbstractCopyCommand extends ChangeCommand implements ICompareCopyCommand
AbstractCommand.NonDirtying
Modifier and Type | Field and Description |
---|---|
protected List<? extends Diff> |
differences
The list of differences we are to merge.
|
protected boolean |
leftToRight
Direction of the merge operation.
|
protected IMerger.Registry |
mergerRegistry
Merger registry.
|
changeDescription, changeRecorder, notifier, notifiers
description, isExecutable, isPrepared, label
Constructor and Description |
---|
AbstractCopyCommand(ChangeRecorder changeRecorder,
Collection<Notifier> notifiers,
List<? extends Diff> differences,
boolean leftToRight,
IMerger.Registry mergerRegistry)
Constructs an instance of this command given the list of differences that it needs to merge.
|
Modifier and Type | Method and Description |
---|---|
boolean |
canExecute() |
Collection<?> |
getAffectedObjects() |
boolean |
isLeftToRight()
Returns true if the command will be applied from left to right side, false otherwise.
|
createChangeRecorder, dispose, disposeChangeRecorder, doExecute, execute, getChangeDescription, getChangeRecorder, prepare, redo, setChangeDescription, undo
canUndo, chain, getDescription, getLabel, getResult, setDescription, setLabel, toString
protected final List<? extends Diff> differences
protected final boolean leftToRight
protected final IMerger.Registry mergerRegistry
public AbstractCopyCommand(ChangeRecorder changeRecorder, Collection<Notifier> notifiers, List<? extends Diff> differences, boolean leftToRight, IMerger.Registry mergerRegistry)
changeRecorder
- The change recorder associated to this command.notifiers
- The collection of notifiers that will be notified of this command's execution.differences
- The list of differences that this command should merge.leftToRight
- The direction in which differences
should be merged.mergerRegistry
- The registry of mergers.public boolean isLeftToRight()
isLeftToRight
in interface ICompareCopyCommand
ICompareCopyCommand.isLeftToRight()
public Collection<?> getAffectedObjects()
getAffectedObjects
in interface Command
getAffectedObjects
in class AbstractCommand
AbstractCommand.getAffectedObjects()
public boolean canExecute()
canExecute
in interface Command
canExecute
in class AbstractCommand
AbstractCommand.canExecute()
Copyright (c) 2006, 2015 Obeo and others. All rights reserved.