Instance Method


Adds the specified rule to the system.


func add(_ rule: GKRule)



A rule object.


Adding rules to the system also adds them to the agenda list, in decreasing order of the rules’ salience values. Rules with the same salience are listed in the agenda in the order in which they were added to the system.

See Also

Managing a System’s List of Rules

var rules: [GKRule]

The list of rules to be executed when evaluating the system.

func add([GKRule])

Adds the specified list of rules to the system.

func removeAllRules()

Removes all rules from the system.