views:

182

answers:

1

I have written a class Foo, and would like to include a Foo object as a property for an NSManagedObject subclass. Is this possible? Can Core Data store information other than strings, booleans, integers, etc.?

+2  A: 

One way is to write an NSValueTransformer that transforms your Foo object to NSData. Make the attribute "Transformable" and give the name of the transformer in the attribute settings.

For more details or information or other options, see the Core Data Programming Guide, in particular the section "Non-Standard Persistent Attributes".

Rüdiger Hanke