MVC Pattern
Login to reply to this topic.
mar, 2008-09-30 11:48
Joined: 2008-09-02
Forum posts: 83

Hi I m new to symbian C++
Can u plz tell me how do i differentiate B/W Model View and Control.
I really dont understand how this thing Works.
I have gone through a large number of materials and got the basics understood somewhat.
But still confused about this MVC Pattern.
Can you help Please.
Or atleast give some references.
Thanx in Advance....


mar, 2008-09-30 12:11
Joined: 2004-11-29
Forum posts: 1419

Its just a way to structure your application, it doesn't really have anything to do with Symbian or with C++ either.
Symbian just provides a few base classes that help you to implement something MVC-like.

For a description of what MVC is, maybe this will help:
http://en.wikipedia.org/wiki/Model-view-controller
http://ootips.org/mvc-pattern.html

The View + help classes for it, is your View (doh) that renders the application state to the screen in a way sensible to the user
The AppUi + classes implementing functionality/features is your controller, that lets the user modify the application state by sending in input
and whatever class (or class structure more likely) you use to represent the application state data is the Model.

And as always with patterns, the lines between what is what is floating and arbitrary and really up to you as a developer to find what division works for _you_ and makes _your_ job easier, and solves your particular problem in the best and most intuitive way...

mar, 2008-09-30 12:32
Joined: 2008-09-02
Forum posts: 83

Thanx Alh
I m using carbide c++ IDE.
plz suggest me in the following.Its very basic thing,(atleast for you)
i ve loaded a simple HelloWorld GUI Application in carbide.
How do i draw, anything, say simple text ,on the client rectangle.
I mean which part of the code i should be changing.

mar, 2008-09-30 13:49
Joined: 2006-04-19
Forum posts: 197


Hi ,

Check this link hope it'l be useful for you.

http://www.titu.jyu.fi/modpa/Patterns/pattern-mvc.html

Thanks&Regards
Isha


"To the question of your life , you are the only Answer. To the problems of your life,you are the only Solution".

mer, 2008-10-01 14:38
Joined: 2004-11-29
Forum posts: 1419


Thanx Alh
I m using carbide c++ IDE.
plz suggest me in the following.Its very basic thing,(atleast for you)
i ve loaded a simple HelloWorld GUI Application in carbide.
How do i draw, anything, say simple text ,on the client rectangle.
I mean which part of the code i should be changing.

I might sound rude, but I think that figuring out that yourself, is a very good exercise for learning symbian programming.
It should be possible to figure out only with some basic C++ knowledge, a debugger and common sense.

It might look big and intimidating at a start, but there isn't really that many parts to it.

Read some more "get started"-documentation, put some breakpoints here and there, draw a bit on paper, try change things around, see what happens, and before you know it you understand how everything fits together.

lun, 2008-10-06 08:21
Joined: 2008-09-02
Forum posts: 83

Hi
thanx alh fr the reply,

Can u tel approximatly how much time it takes for c++ programmer to learn symbian OS c++.
How much time did u have to practice.
No pro if you dnt wanna answer silly qustions.

Thanx again.

lun, 2008-10-06 08:22
Joined: 2008-09-02
Forum posts: 83

By the way sorry fr late reply/.......

lun, 2008-10-06 11:51
Joined: 2004-11-29
Forum posts: 1419

Thats very individual and hard to give a relevant estimate of...

Depends a _lot_ on how much and what kind of experience you have before, how well you really know C++, and how easy you have to learn

Personally, I don't think the basics is that hard, the C++ language in itself is exactly the same, but you don't have the STL in symbian, which can make it very confusing for people who havn't realized the difference between C++ and STL.
So there is some new stuff you have to learn, the basic structure with the event driven active objects model and cleanupstacks and leaves.
And descriptors... (my tip is, use RBuf as much as possible...)

The hard part with symbian, that you never really get over, is more on the API level, what API:s is there, what of the ones that is there actually work, and how you use the ones that do work. On that part I think I still learn new stuff every week.
But I think thats kindof natural for such a quickly evolving product. (though sometimes I do wish for a bit more consistency in design)

Learning to navigate the forums, knowledgebases, and documentation is a must.

Documentation is a lot better today then it was just a few years ago, and nowadays, you can actually write parts of your app using STL, or even OpenC though you ofcourse still have to interface symbian APIs for any system specific stuff.

lun, 2008-12-01 12:49
Joined: 2008-09-02
Forum posts: 83

copyright 2003-2009 NewLC SARL