
72
Chapter 4: Architecting Flex Applications
Flex Store object model figure
The following figure shows the object model for the Flex Store application and identifies each
object as part of the model, view, or controller:
FlexStore
The FlexStore object is the top-level object in the Flex Store application. It contains the rest of the
application objects, including the standard Flex objects and custom objects. This object is a view
object because it is the top-level object in the user interface, but it also contains the rest of the
application.
catalog
The catalog object is a nonvisual object that contains data about the products available for
purchase. This object is a model object because its primary purpose is to represent products.
ShoppingCart
The ShoppingCart object is a nonvisual object that stores items a user selects for purchase. This
object is a model object because its primary purpose is to represent a set of items that the user
selects for purchase. It also keeps track of the number of items selected for purchase and the total
cost of the items.
CartView
The CartView object is a visual object that displays the current ShoppingCart items in the user
interface. This object must get the current data from the ShoppingCart object and display it
appropriately in the user interface; this requirement is described in
“Determining component
types and a messaging strategy” on page 73
.
ProductThumbnail
The ProductThumbnail object is a visual object that displays a thumbnail image, name, and price
for each product in the catalog object.
ShoppingCart
Model
FlexStore
View
catalog
Model
CartView
View
ProductDetail
View
ProductThumbnail
View
Thumbnail
View
Checkout
View
Содержание FLEX-GETTING STARTED WITH FLEX
Страница 1: ...Getting Started with Flex...
Страница 4: ...4 Contents...
Страница 22: ...22 Chapter 1 Introducing Flex...