• 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: Core-Data Non-Standard Attributes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Core-Data Non-Standard Attributes


  • Subject: Re: Core-Data Non-Standard Attributes
  • From: Jeff LaMarche <email@hidden>
  • Date: Wed, 4 Jan 2006 12:04:02 -0500


On Jan 4, 2006, at 11:28 AM, Volker Schumacher wrote:

Apple provides some documentation about storing non-standard attributes
[http://developer.apple.com/documentation/Cocoa/Conceptual/CoreData/ Articles/cdNSAttributes.html],
but they are only talking about "structures supported by key-value coding (NSPoint, NSSize, NSRect, or NSRange)" in the "Non-Object Attribute" section,
so i'm a little bit confused how to implement custom attributes for my float-array or other C-structs.
Can i do it the same way as described in the "Non-Object Attribute" section of that document?

Yep. You're responsible for doing the translating between your non- object and the concrete attribute that will actually store it. You can do it any way you want. You could, for example, convert the floats to NSNumbers and shove them into a dictionary, or you could write a method to create a comma separated string of the values, or whatever ways tickles your fancy as long as you can turn it into an object, and then back from that object. Everything else should work the same as described in the page you reference.
_______________________________________________
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: 
 >Core-Data Non-Standard Attributes (From: Volker Schumacher <email@hidden>)

  • Prev by Date: Custom Objects in an NSTextView
  • Next by Date: Re: Custom Objects in an NSTextView
  • Previous by thread: Core-Data Non-Standard Attributes
  • Next by thread: Re: Core-Data Non-Standard Attributes
  • Index(es):
    • Date
    • Thread