Graphics Programs Reference
In-Depth Information
to understand, which makes it easier to maintain and debug, as well as share with other
programmers on your team.
Figure 28.4 Model-View-Controller-Store diagram
You've already seen and used MVCS in the Homepwner application. In
Homepwner
, you
had two store objects:
BNRItemStore
and
BNRImageStore
. This freed the table
view controller to focus on its work as the table view's data source instead of mucking
about with fetching individual
BNRItem
s.
But what about the application you just completed,
Nerdfeed
?
Nerdfeed
has request logic
for getting data from a web service, and that code is in a controller object -
ListViewController
.
Let's fix that now. In this chapter, we will add a store class to
Nerdfeed
and move all of
the request logic out of
ListViewController
. We will also add another web service
request and new features to
Nerdfeed
to demonstrate the benefits of MVCS.