• 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
Bindings Model<->View Only? [was Re: Cocoa bindings one- or bi-directional]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Bindings Model<->View Only? [was Re: Cocoa bindings one- or bi-directional]


  • Subject: Bindings Model<->View Only? [was Re: Cocoa bindings one- or bi-directional]
  • From: Des Courtney <email@hidden>
  • Date: Fri, 27 May 2005 09:07:49 -0500

At Fri, 27 May 2005 02:14:47, mmalcolm crawford <email@hidden> wrote:

You typically should not bind one model object to another. The primary goal of bindings is to keep user views synchronised with models. You bind an attribute of a UI widget to the property of a
model object...

At Fri, 27 May 2005 05:39:47, Scott Anguish <email@hidden> wrote:

     Apple doesn't endorse or recommend connecting UI to model
directly, nor model<->model bindings

Is there a specific point in Apple's documentation that makes this clear? It looks like this is what I was trying to do last week with binding an NSTableView with NSUserDefaults. (From the binding system's point of view, the NSArray used by the table was a "model" object, even though from MY point of view, it existed solely for the benefit of the UI and not for any persistent store or other state info.) I've looked through the bindings and key-value docs, but I may have skimmed over the exact point where this design intent was specified...

It also looks like my concept of what a model is much more restricted
  than how the design pattern describes it.  My understanding was that
  a Gang Of Four "model" refers only to persistent state, not just
  transient "scratch data" that exists for the benefit of processing.

Des

--
Des Courtney - Mascon Global, Ltd.
Computer Programmer - Macintosh Specialist
<mailto:email@hidden>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Prev by Date: Re: Cocoa bindings one- or bi-directional
  • Next by Date: Re: Many many tabs
  • Previous by thread: (update)Re: NSFilePromisePboardType example that works with MacOSX 10.3 (also problem with pasteboard:provideDataForType:)
  • Next by thread: Data driven outlineview with icons?
  • Index(es):
    • Date
    • Thread