• 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: NSTreeController: do leaf and non-leaf nodes have to be of the same class?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTreeController: do leaf and non-leaf nodes have to be of the same class?


  • Subject: Re: NSTreeController: do leaf and non-leaf nodes have to be of the same class?
  • From: Greg Hurrell <email@hidden>
  • Date: Thu, 18 May 2006 21:40:49 +0200

El 18/05/2006, a las 21:19, Greg Hurrell escribió:

El 18/05/2006, a las 20:21, Ondra Cada escribió:

The best (arguably) and most convenient (definitely) solution is to make your "group" respond to these messages, returning reasonable default "empty" values. That're those "kludgey methods" of yours.

On further inspection it appears that this is exactly what the "Raises for not applicable keys" checkbox is for... searching for that string on Google yields 7 hits (wow), but one of them is this Apple document:


http://tuvix.apple.com/documentation/Cocoa/Reference/CocoaBindingsRef/ CocoaBindingsRef.pdf

Which on page 35 says that "Raises for not applicable keys" is:

A Boolean value that specifies if an exception is raised when a binding is bound to a key that does not exist.
If YES, an exception is raised when the bound key is not applicable, otherwise the NSNotApplicableMarker is returned..

So looks like that's exactly what I need, and I won't have to write phoney methods in my "group" class.


Cheers,
Greg


Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
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

References: 
 >NSTreeController: do leaf and non-leaf nodes have to be of the same class? (From: Greg Hurrell <email@hidden>)
 >Re: NSTreeController: do leaf and non-leaf nodes have to be of the same class? (From: Ondra Cada <email@hidden>)
 >Re: NSTreeController: do leaf and non-leaf nodes have to be of the same class? (From: Greg Hurrell <email@hidden>)

  • Prev by Date: RE: Binding to Accessors of Application Delegate
  • Next by Date: Problem using custom entity class with subclasses NSArrayController
  • Previous by thread: Re: NSTreeController: do leaf and non-leaf nodes have to be of the same class?
  • Next by thread: iWork Pages Plugin
  • Index(es):
    • Date
    • Thread