org.puremvc.php.interfaces

# Class: IController Source Location: /interfaces/IController.php
### Interface Overview
The interface definition for a PureMVC Controller. #### Author(s): | ### Methods executeCommand registerCommand removeCommand
### Class Details [line 38] The interface definition for a PureMVC Controller. In PureMVC, an IController implementor follows the 'Command and Controller' strategy, and assumes these responsibilities: Remembering which ICommand s are intended to handle which INotifications . Registering itself as an IObserver with the View for each INotification that it has an ICommand mapping for. Creating a new instance of the proper ICommand to handle a given INotification when notified by the View . Calling the ICommand 's execute method, passing in the INotification . #### Tags:
see: | org.puremvc.php.interfaces ICommand
see: | org.puremvc.php.interfaces INotification
[ Top ] ### Class Methods ### method executeCommand [line 56]
`void executeCommand( INotification $notification)`
Execute the ICommand previously registered as the handler for INotification s with the given notification name. #### Tags:
access: | public
#### Parameters:
notification | $notification | the INotification to execute the associated ICommand for
[ Top ] ### method registerCommand [line 48]
`void registerCommand( notificationName $notificationName, commandClassRef $commandClassRef)`
Register a particular ICommand class as the handler for a particular INotification . #### Tags:
access: | public
#### Parameters:
notificationName | $notificationName | the name of the INotification
commandClassRef | $commandClassRef | the Class of the ICommand
[ Top ] ### method removeCommand [line 63]
`void removeCommand( notificationName $notificationName)`
Remove a previously registered ICommand to INotification mapping. #### Tags:
access: | public
#### Parameters:
notificationName | $notificationName | the name of the INotification to remove the ICommand mapping for
[ Top ] Documentation generated on Tue, 30 Sep 2008 08:05:44 -0700 by phpDocumentor 1.4.0