vsTASKER 7 User Manual
×
Menu
Index

Rule

 
A Rule is a Context piece of code that is called until the rule is fired (triggered).
A Rule is considered fired on two conditions only:
 
Double click on a Context symbol to open it and display its content (Rules) on the Diagram panel.
Double click on the background to close it and return to the Context view.
 
 
A Rule can access directly all data and methods defined in the Context as well as all vsTASKER API and internal data.
 
 
On the background:
Edit Context: call the Context property window.
 
Add Rule: append a new Rule in the list (at the end).
 
Up: close the View and return to the Context view (same as double clicking on the background)
 
When a Rule is selected:
Edit Rule: call the Rule property window.
 
Move Up: move up the selected Rule in the list, to be processed earlier.
 
Move Down: move down the selected Rule in the list, to be processed later.
 
Rename: no effect, Rule has no name.
 
Cut: allow moving one rule from one Context to one another. Copied and deleted locally.
 
Copy: copy the selected Rule into the clipboard.
 
Duplicate: copy and append the selected Rule.
 
Delete: remove the Rule from the list (cannot undo).
 
 
To add rules into a Context, you must first open a Context by double clicking its symbol. Any click on this button appends a new Rule into the context.
 
 
scen() or S: is a macro that returns a pointer to the Scenario instance that holds the Entity instance that holds the Knowledge instance that holds the current Context.
ent() or E: is a macro that returns a pointer to the Entity instance that holds the Knowledge instance that holds the current Context.
know() or K: is a macro that returns a pointer to the Knowledge instance that holds the current Context.