public abstract class AbstractDispatchLayerEdit extends Object implements Edit<DispatchStack>
Modifier | Constructor and Description |
---|---|
protected |
AbstractDispatchLayerEdit(DispatchStack s) |
Modifier and Type | Method and Description |
---|---|
DispatchStack |
doEdit()
Perform the edit
|
protected abstract void |
doEditAction(DispatchStackImpl stack)
Do the actual edit here
|
DispatchStack |
getSubject()
Return the object to which this edit applies
|
boolean |
isApplied()
Has the edit been applied yet?
|
void |
undo()
Undo the edit, reverting the subject to the state it was in prior to the
edit
|
protected void |
undoEditAction(DispatchStackImpl stack)
Undo any edit effects here
|
protected AbstractDispatchLayerEdit(DispatchStack s)
public final DispatchStack doEdit() throws EditException
Edit
doEdit
in interface Edit<DispatchStack>
EditException
- if the edit fails. If an edit throws EditException it should
try to ensure the subject is unaltered. Where this is
impossible consider breaking edits down into a compound edit.protected abstract void doEditAction(DispatchStackImpl stack) throws EditException
processor
- The ProcessorImpl to which the edit appliesEditException
protected void undoEditAction(DispatchStackImpl stack)
public final DispatchStack getSubject()
Edit
getSubject
in interface Edit<DispatchStack>
public final boolean isApplied()
Edit
isApplied
in interface Edit<DispatchStack>
public final void undo()
Edit
undo
in interface Edit<DispatchStack>
Copyright © 2015–2016 The Apache Software Foundation. All rights reserved.