Package puremvc :: Package patterns :: Module command :: Class SimpleCommand
[hide private]
[frames] | no frames]

type SimpleCommand

source code

              object --+    
                       |    
interfaces.INotifier --+    
                       |    
       observer.Notifier --+
                           |
     interfaces.ICommand --+
                           |
    interfaces.INotifier --+
                           |
                          SimpleCommand

A base ICommand implementation.

Your subclass should override the execute method where your business logic will handle the INotification.


See Also:
Controller, Notification, MacroCommand
Instance Methods [hide private]
 
execute(self, notification)
Fulfill the use-case initiated by the given INotification.
source code

Inherited from observer.Notifier: __init__, sendNotification

Class Variables [hide private]

Inherited from observer.Notifier: facade

Method Details [hide private]

execute(self, notification)

source code 

Fulfill the use-case initiated by the given INotification.

In the Command Pattern, an application use-case typically begins with some user action, which results in an INotification being broadcast, which is handled by business logic in the execute method of an ICommand.

Parameters:
  • notification - the INotification to handle.
Overrides: interfaces.ICommand.execute