|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectsophware.home.logic.Macro
public class Macro
Macro is a collection of MacroSteps that can
be executed as group.
Optionally, a macro will monitor a Condition that can trigger
the executon of the macro automatically
MacroStep,
Condition,
Serialized Form| Constructor Summary | |
|---|---|
Macro(java.lang.String name,
Condition trigger,
java.util.Vector<MacroStep> steps)
Constructs a Macro |
|
Macro(java.lang.String name,
java.util.Vector<MacroStep> steps)
Constructs a Macro |
|
| Method Summary | |
|---|---|
void |
evaluate()
Evaluate the state of the trigger and execute if trigger is on |
void |
execute()
execute the steps of the macro unconditionally |
protected void |
finalize()
|
java.lang.String |
getName()
Get name of this macro |
void |
stateChanged(StateObject trigger)
monitors trigger, if trigger is true executes the macro steps |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Macro(java.lang.String name,
java.util.Vector<MacroStep> steps)
Macro
This macro lacks a trigger and therefore must be executed manually or as part of another macro.
name - the name of this macrosteps - the MacroStepsevaluate(),
execute()
public Macro(java.lang.String name,
Condition trigger,
java.util.Vector<MacroStep> steps)
Macro
If the trigger is ON when this constructor is created the macro will not be executed until the next time it transitions to ON. You may call the evaluate() or execute() method to force immediate execution if that is what is desired.
name - the name of this macrotrigger - the condition that triggers this macrosteps - the MacroStepsevaluate(),
execute()| Method Detail |
|---|
public java.lang.String getName()
getName in interface Namedpublic void evaluate()
If trigger is already on before the
Macro if the trigger is on
public void stateChanged(StateObject trigger)
stateChanged in interface StateChangeListenertrigger - trigger has updatedpublic void execute()
execute in interface MacroStepprotected void finalize()
finalize in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||