Creation, Instantiation and Use of Controllers

2 views
Skip to first unread message

Leif Singer

unread,
Jan 4, 2010, 8:36:31 PM1/4/10
to objec...@googlegroups.com
Hello,

I've seen many examples for Cappuccino applications that merely use an ApplicationController and have that arrange any views and coordinate communication between those. This has led me to adopt that style for my own programming, why I guess will create problems with middle- or larger-sized projects.

Therfore, I'd like to know what the "best practice" of doing this is. Do I use a custom controller class for every custom view class I create? Or even *any* view class I instantiate? Where and when do I create controllers and views? I'm missing some sort of big picture here, as I'm also not overly familiar with Objective-C and Cocoa programming.

Could someone sketch that out for me (and the rest of the mailing list that might want to know)?

Thanks in advance
Leif

David Hess

unread,
Jan 4, 2010, 9:05:02 PM1/4/10
to objec...@googlegroups.com

Here's Cocoa's take on the MVC (Model-View-Controller) pattern:

http://developer.apple.com/iphone/library/documentation/Cocoa/Conceptual/CocoaFundamentals/CocoaDesignPatterns/CocoaDesignPatterns.html#/
/apple_ref/doc/uid/TP40002974-CH6-SW1

It should apply to Cappuccino pretty closely.

Dave

> --
>
> You received this message because you are subscribed to the Google
> Groups "Cappuccino & Objective-J" group.
> To post to this group, send email to objec...@googlegroups.com.
> To unsubscribe from this group, send email to objectivej+...@googlegroups.com
> .
> For more options, visit this group at http://groups.google.com/group/objectivej?hl=en
> .
>
>
>

David Hess

unread,
Jan 4, 2010, 9:08:20 PM1/4/10
to objec...@googlegroups.com

A shorter link that shouldn't break this time:

http://tinyurl.com/yhlegqr

Dave

Reply all
Reply to author
Forward
0 new messages