#import "INotification.h" /** * The interface definition for a PureMVC Controller. * *

* In PureMVC, an IController implementor * follows the 'Command and Controller' strategy, and * assumes these responsibilities: *

* * @see INotification, ICommand */ @protocol IController /** * Execute the ICommand previously registered as the * handler for INotifications with the given notification name. * * @param notification the INotification to execute the associated ICommand for */ -(void)executeCommand:(id)notification; /** * Check if a Command is registered for a given Notification * * @param notificationName * @return whether a Command is currently registered for the given notificationName. */ -(BOOL)hasCommand:(NSString *)notificationName; /** * Register a particular ICommand class as the handler * for a particular INotification. * * @param notificationName the name of the INotification * @param commandClassRef the Class of the ICommand */ -(void)registerCommand:(NSString *)notificationName commandClassRef:(Class)commandClassRef; /** * Remove a previously registered ICommand to INotification mapping. * * @param notificationName the name of the INotification to remove the ICommand mapping for */ -(void)removeCommand:(NSString *)notificationName; @end