Package net.officefloor.model.change
Interface Change<T>
- All Known Subinterfaces:
ChangeList<T>
- All Known Implementing Classes:
AbstractChange,AggregateChange,DisconnectChange,NoChange
public interface Change<T>
A change to be applied/reverted.
All operations utilise this to enable do/undo functionality.
- Author:
- Daniel Sagenschneider
-
Method Details
-
getTarget
T getTarget()Obtains the target to which thisChangeapplies.- Returns:
- Target to which this
Changeapplies.
-
getChangeDescription
String getChangeDescription()Obtains a description of theChange.- Returns:
- Description of the
Change.
-
canApply
boolean canApply()Indicates if can apply this
Change.Typically there will be
Conflictinstances providing detail on why theChangecan not be applied.- Returns:
trueif can apply thisChange.- See Also:
-
apply
void apply()Applies thisChange. -
revert
void revert()Reverts this
Change(after being applied).This enables do/undo functionality.
-
getConflicts
Conflict[] getConflicts()
-