diff -r 9fdd8dba529c -r 8b883753394a BLIP/BLIPDispatcher.h --- a/BLIP/BLIPDispatcher.h Sat May 24 17:25:06 2008 -0700 +++ b/BLIP/BLIPDispatcher.h Sun Jul 13 10:42:50 2008 -0700 @@ -10,8 +10,9 @@ @class MYTarget, BLIPMessage; -/** Routes BLIP messages to targets based on a series of rule predicates. - Every BLIPConnection has a BLIPDispatcher, which is initially empty but you can add rules +/** Routes BLIP messages to targets based on a series of rules. + + Every BLIPConnection has a BLIPDispatcher, which is initially empty, but you can add rules to it. Every BLIPListener also has a dispatcher, which is inherited as the parent by every @@ -33,11 +34,13 @@ the parent, if there is one. */ @property (retain) BLIPDispatcher *parent; +/** Convenience method that adds a rule that compares a property against a string. */ +- (void) addTarget: (MYTarget*)target forValueOfProperty: (NSString*)value forKey: (NSString*)key; + +#if ! TARGET_OS_IPHONE /* NSPredicate is not available on iPhone, unfortunately */ /** Adds a new rule, to call a given target method if a given predicate matches the message. */ - (void) addTarget: (MYTarget*)target forPredicate: (NSPredicate*)predicate; - -/** Convenience method that adds a rule that compares a property against a string. */ -- (void) addTarget: (MYTarget*)target forValueOfProperty: (NSString*)value forKey: (NSString*)key; +#endif /** Removes all rules with the given target method. */ - (void) removeTarget: (MYTarget*)target;