Don Alejandro
Don Alejandro

Reputation: 885

Would 'type: Undefined' default to AnyObject?

In the image below, if I don't assign the attribute a type, what type will it have by default?

enter image description here

Upvotes: 0

Views: 65

Answers (1)

Willeke
Willeke

Reputation: 15598

From Apple's documentation:

NSUndefinedAttributeType is valid for transient properties—Core Data will still track the property as an id value and register undo/redo actions, and so on. NSUndefinedAttributeType is illegal for non-transient properties.

Type Undefined is used for non-standard type properties. When Xcode creates a NSManagedObject subclass, the type is UNKNOWN_TYPE.

Upvotes: 2

Related Questions