Package teamwork :: Package action :: Module PsychActions :: Class ActionCondition
[hide private]
[frames] | no frames]

Class ActionCondition

source code

Class for specifying a template for matching joint actions

Instance Methods [hide private]
 
__init__(self, only=False, count=False) source code
 
addCondition(self, verb) source code
 
delCondition(self, verb) source code
 
__len__(self) source code
bool or int
match(self, actions)
Returns: If self.count is False, then return True iff the given joint action meets this condition; otherwise, return number of matching actions, or 0 if match fails
source code
 
__str__(self) source code
 
__xml__(self) source code
 
parse(self, element) source code
Instance Variables [hide private]
bool count
True iff we are interested in how many actions match, not just a boolean value (default is False)
bool only
True iff only actions in the verb set are allowed (default is False)
str→True verbs
dictionary of verbs that this condition matches
Method Details [hide private]

match(self, actions)

source code 
Returns: bool or int
If self.count is False, then return True iff the given joint action meets this condition; otherwise, return number of matching actions, or 0 if match fails