• 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: setValue:forKey: and to-many relationships
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: setValue:forKey: and to-many relationships


  • Subject: Re: setValue:forKey: and to-many relationships
  • From: Christian Ziegler <email@hidden>
  • Date: Fri, 23 Apr 2010 14:13:41 +0200

Hi all!

First of all shame on me, I didn't read this article entirely (one of my very very bad traits ;-) ), thanks very much though for pointing it out. Given the very good arguments I think it's better to create subclasses. Also thanks to Mike I figured out how to easily create those subclasses. Very cool!

Cheers,
Chris

On 23.04.2010, at 13:01, Mike Abdullah wrote:

> ah, good point. Seems pretty ugly though as you start suggesting that all managed objects support those methods. It only takes a moment to generate a subclass that does this.
>
> On 23 Apr 2010, at 11:28, Roland King wrote:
>
>> yes there is - and it's in the documentation too
>>
>> http://developer.apple.com/mac/library/documentation/cocoa/conceptual/CoreData/Articles/cdAccessorMethods.html
>>
>> "If you are not using a custom class, to suppress compiler warnings you can declare the properties in a category of NSManagedObject:"
>>
>> and it gives you an example there as well.
>>
>>
>> On 23-Apr-2010, at 6:21 PM, Mike Abdullah wrote:
>>
>>>
>>> On 23 Apr 2010, at 10:46, Christian Ziegler wrote:
>>>
>>>> Hi all!
>>>>
>>>> I would like to step in here for a related question. Is there any way to get rid of the compiler warnings if you use the generated accessors without writing a subclass of NSManagedObject and adding properties and method declarations?
>>>
>>> No there isn't. But the xcode modeller can easily generate those method declarations for you when writing a new class.
>>>
>>> _______________________________________________
>>>
>>> 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
>>
>

_______________________________________________

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

References: 
 >setValue:forKey: and to-many relationships (From: Dave DeLong <email@hidden>)
 >Re: setValue:forKey: and to-many relationships (From: Keary Suska <email@hidden>)
 >Re: setValue:forKey: and to-many relationships (From: Christian Ziegler <email@hidden>)
 >Re: setValue:forKey: and to-many relationships (From: Mike Abdullah <email@hidden>)
 >Re: setValue:forKey: and to-many relationships (From: Roland King <email@hidden>)
 >Re: setValue:forKey: and to-many relationships (From: Mike Abdullah <email@hidden>)

  • Prev by Date: Re: setValue:forKey: and to-many relationships
  • Next by Date: Re: NSApplicationMain question
  • Previous by thread: Re: setValue:forKey: and to-many relationships
  • Next by thread: Re: setValue:forKey: and to-many relationships
  • Index(es):
    • Date
    • Thread