• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Parent-child Design Pattern
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Parent-child Design Pattern


  • Subject: Re: Parent-child Design Pattern
  • From: Greg Guerin <email@hidden>
  • Date: Sun, 12 Jun 2011 13:12:08 -0700

Martin Hewitson wrote:

What I'm unsure about is, how to deal with the children objects. I will, in principle, have a ChildView. This raises some questions:

1) Should I have a ChildViewController class?


I don't think there's a single answer. Parent/child relationships can be presented in many ways. For example, see here:

http://designingwebinterfaces.com/designing-web-interfaces-12-screen- patterns

Many of those designs have some form of hierarchical data models, yet the views and view controllers may not have the same structure.

You should figure out what the view relationships are, then design view controllers accordingly. The role of the class is a VIEW controller, not a MODEL controller; it doesn't have to mirror the MODEL's structure.

  -- GG


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Prev by Date: Re: Parent-child Design Pattern
  • Next by Date: Re: Memory Management for XML Parsing
  • Previous by thread: Re: Parent-child Design Pattern
  • Next by thread: Is it possible to create a Finder-like icon in Dock?
  • Index(es):
    • Date
    • Thread