8 Replies Latest reply on Aug 5, 2008 3:54 AM by nikos101

    MCV cairngorm practise long winded?

    nikos101 Level 2
      With the MCV cairngorm practise it seems a really long winded way pass data about, it seems that it is easier to pass data about in Java. What do you think?
        • 1. Re: MCV cairngorm practise long winded?
          Gregory Lafrance Level 6
          BUMP - I was really hoping someone could respond to this post, as I'm interested in hearing possible solutions.
          • 2. Re: MCV cairngorm practise long winded?
            Bryan Dresselhaus
            I'm starting to despise cairngorm. I took over a code base of a number of flex projects that are tens of thousands of lines of code long. Trying to following between delegates, commands, event listeners, and various views is such a headache. Just build loosely coupled components with custom events and thats more than sufficient. Cairngorm is overkill for large projects.
            • 3. Re: MCV cairngorm practise long winded?
              Gregory Lafrance Level 6
              Thanks for sharing your experience. I've always heard the MVC paradigm touted as the way to go. If others have additional comments, either for/against cairngorm or MVC in general, it would be great.
              • 4. MCV cairngorm practise long winded?
                VarioPegged Level 2
                You know the drill: design patterns exist because developers have found common implementations to handle specific tasks.

                I tend to guard against adopting anything that I’m told I should use. I want to experience the touted merits first-hand. In the same breath I’ll say that I respect the collective wisdom of a body of individuals who no doubt have gone through the same trials and tribulations we’re about to embark upon when designing our app. So I try what they sell. Quite often some aspects work better than expected, and some worse.

                Many developers revel in the code they write, getting a sense of satisfaction solving some coding problem, or marveling in how seamlessly this widget instantiated that one and called this method to do that action. Many of these developers also love to write overly complex code. They’re the ones I worry about telling me I should be using MVC this and that.

                Determining whether one should use any particular design for your app really boils down to what’s expected from the application over time. Look at the most efficient way to build that app and get it done, but build it intelligently, whether using a design pattern or not. Strive for loose coupling first and foremost like Bryan mentions above.

                We do use the MVC pattern (not Cairngorm) in app design frequently, but in making the recommendation whether you should use the MVC pattern in your app design or not, I’d simply say, build an app and try it for yourself. You’ll quickly see whether it’s overkill or not.

                TS
                • 5. Re: MCV cairngorm practise long winded?
                  Peter Lorent Level 2
                  But why Cairngorm? MVC comes in some may different flavours, from very basic implementations of a Model, View and Controller to Cairngorm and the like which are mostly used in large applications. MVC is just about responsibilities and re-usability. In my honest opinion MVC is most definitely the way to go but in most cases a simple setup suffices.
                  • 6. Re: MCV cairngorm practise long winded?
                    nikos101 Level 2
                    thanks for all the helpful replies
                    • 7. Re: MCV cairngorm practise long winded?
                      BJWILD
                      We use cairngorm where I work and I would have to agree that it is a little long winded but using a code generator can help with that.

                      There are many options for flex MVC frameworks out there, and while cairngorm may have its drawbacks, it certainly has a lot of benefits too. We use it mainly so our team follows the same standards when coding so we all know basically how each others projects fit together. It helps in the long run when you have to maintain another persons code.

                      I think cairngrom is great, it may not be the best flavour of the lot but I believe it's better to use a standard, popular and well supported framework than nothing at all.
                      • 8. Re: MCV cairngorm practise long winded?
                        nikos101 Level 2
                        I agree. However if you are one or 2 man band I think its would not be worth the effort