Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

6. The CommandMap in action

Chapter 6. The CommandMap in action

Earlier in this book, we described a command as being a ‘snack-sized controller’. In any meaningful application the developer has to find ways to tie the important players together—a click on a view might require a service to load some data, from which a model is updated (if there are no errors), and so on. This ‘tying together’ is the realm of the controller code—and it’s usually the most complex and brittle code in your application. The CommandMap and the Command class exist to achieve this ‘tying together’ in a way that is less complex and less brittle than the typical controller approach.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint