Condition
Kind of class: | public class |
---|---|
Package: | |
Inherits from: |
|
Classpath: | org.asaplibrary.util.actionqueue.Condition |
File last modified: | Wednesday, 11 May 2011, 18:54:39 |
A Condition is an Action that runs an evaluation method and returns its result: true or false.
Conditions may be used in ActionQueues or ActionRunners - see ActionQueue.addCondition.
Usage
-
var condition:Condition = new Condition(evaluateInput, [1]); condition.run(); trace(condition.isMet()); // true private function evaluateInput (inParam:int) : Boolean { return (inParam > 0) ? true : false; }
Summary
Instance methods
isMet
function isMet() : Boolean
Returns
- True if the condition is met; otherwise false.
run
override function run() : *
Calls the evaluation method.
Overrides
Returns
- True when the condition is met; otherwise false.