KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jbpm > context > log > VariableUpdateLog


1 package org.jbpm.context.log;
2
3 import org.jbpm.context.exe.*;
4
5 public abstract class VariableUpdateLog extends VariableLog {
6   
7   public VariableUpdateLog() {
8   }
9
10   public VariableUpdateLog(VariableInstance variableInstance) {
11     super(variableInstance);
12   }
13
14   public abstract Object JavaDoc getOldValue();
15   public abstract Object JavaDoc getNewValue();
16   
17   public String JavaDoc toString() {
18     return "varupdate["+variableInstance+"="+getNewValue()+"]";
19   }
20
21   public void undo() {
22     variableInstance.setValue( getOldValue() );
23   }
24 }
25
Popular Tags