View Full Version : When to use MVC?
08-25-2009, 08:55 PM
I have been studying AS3 for 6 months now and I have now reached another epic point of confusion. My question is when should I use the MVC framework and when should I not?
08-26-2009, 12:04 PM
MVC is an abstraction, it's not a framework ;)
MVC is a way to build your application, i.e. it is a set of rules, that defines what kind of classes do what.
There actually is a framework with a somewhat similar name - PureMVC, but using it is almost up to you. I never used it, unless for testing / general experience. IMO it's highly bloated and unreasonably complicated, besides not being well suited for smaller or modular applications. And, while it may make sense in developing of big desktop applications, I say it's not what you'd like to use for web, where every kilobyte counts :)
There are several architectural frameworks out there (like PureMVC), Cairngorm, MATE and SWIZ would be the most commonly used. I personally prefer MATE, but, again, I would be using it only in the project that:
1. Uses Flex framework.
2. Is expected to be > 1 Mb in size.
Well, maybe the size isn't a best parameter to measure the amount of code you will be writing for the project, but, it will probably give you a general idea.
08-26-2009, 08:59 PM
Thanks for the info wvxvw. Yesterday I had looked at the PureMVC Framwork. And I see what you mean by saying PureMVC is unreasonably complicated. But from what I've read it seems like it could go either way, some love it, some hate it. I guess it all boils down to the scale of the project no?
I'm think i'm going to try and wrap my head around PureMVC and see exactly what all the hubbub is all about.
vBulletin® v3.8.5, Copyright ©2000-2013, Jelsoft Enterprises Ltd.