• 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
CoreData and nil values?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

CoreData and nil values?


  • Subject: CoreData and nil values?
  • From: Marc Respass <email@hidden>
  • Date: Mon, 29 Jan 2007 11:21:26 -0500

Hi All,

I have a need to get the data out of my managed objects and make a dictionary and encode it but I can't encode if the value is null so I'd like to get empty strings but I can't figure out how to set the default value to be an empty string in XCode (I tried "" but it comes out as "\"\"") so I'm wondering what the best choice is. I have about 16 String attributes in one entity and there's no need to setup custom accessors for each attribute. I'm thinking that I could make a custom managed object and override valueForKey to return empty string if the value is really NSNull. Suggestions?

Thanks a lot
Marc
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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: Strange results when converting NSDate timeIntervalSinceReferenceDate to NSPoint
  • Next by Date: Re: NSButton Text Color?
  • Previous by thread: Re: Application information that all users can see
  • Next by thread: NSViewAnimation and fading in NSWindow
  • Index(es):
    • Date
    • Thread