Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | Last revisionBoth sides next revision | ||
en:toolworks:docs:apparatus:deferred [2022/06/01 20:05] – vladius | en:toolworks:docs:apparatus:deferred [2022/06/05 21:40] – vladius | ||
---|---|---|---|
Line 58: | Line 58: | ||
</ | </ | ||
+ | ====== Applying ===== | ||
+ | |||
+ | Until when? This is quite a logical question when dealing with something that is deferred by design. And the default answer is "when the time is right" | ||
+ | |||
+ | The default automatic behavior minimizes the effort and guarantees that the Deferreds get applied accordingly, | ||
+ | |||
+ | Deferreds Applicators are created explicitly, by calling the [[appi> | ||
+ | { // Start of the explicit scope. | ||
+ | auto Applicator = Mechanism-> | ||
+ | Mechanism-> | ||
+ | // Your first mechanic producing deferred operations. | ||
+ | }); | ||
+ | // The Deferreds won't be applied at this point. | ||
+ | Mechanism-> | ||
+ | // Your second mechanic producing deferred operations. | ||
+ | }); | ||
+ | // Now the Deferreds get actually applied. | ||
+ | } // End of the explicit scope. | ||
+ | </ | ||
+ | |||
+ | Note that the Applicator is actually introduced within its own explicit scope (the curly brace' |