puremvc
|
 |
« Reply #1 on: January 03, 2012, 08:37:58 » |
|
The Proxy, or a Value Object is probably the best place as opposed to a Command.
If you don't want the Proxy to have this logic, you could have a Value Object with properties a and b and the method figureFoo(), or better yet an implicit accessor get foo(), so that it appears you have a derived property foo (assuming you're using AS3, if not, then just a getFoo()).
The reasoning for not putting domain logic into a command (where business logic lives) is that it makes it difficult to reuse the Model tier - one of the most valuable outcomes of using MVC. For instance, my current client has a Flex web application that we now have a desktop viewer for, as well as an iPad viewer. The use cases and consequent business logic varies from app to app, but the Model tier remains the same.
-=Cliff>
|