Whatever message this page gives is out now! Go check it out!
future.runAfterEither(other, action)| Parameter | Description |
|---|---|
| other | Required. The other Future to race. |
| action | Required. A function with no parameters that performs work (void semantics). |
<cfscript>
f1 = runAsync(function() { return 1; });
f2 = runAsync(function() {
sleep(1000);
return 2;
});
after = f1.runAfterEither(f2, function() {
variables.ran = "YES";
});
after.get();
writeOutput(variables.ran); // YES
</cfscript>