Re: Validating a non-optional transient Core Data property - it can be erased?!
Re: Validating a non-optional transient Core Data property - it can be erased?!
- Subject: Re: Validating a non-optional transient Core Data property - it can be erased?!
- From: Quincey Morris <email@hidden>
- Date: Thu, 13 Nov 2008 09:40:44 -0800
On Nov 13, 2008, at 09:17, Arthur C. wrote:
There's also a way of localizing the built-in error messages,
which >may be another solution to your first question if you just
want to >vary the wording a bit:>> http://developer.apple.com/documentation/Cocoa/Conceptual/CoreData/Articles/cdUsingMOM.html#/
/apple_ref/doc/uid/TP40005190-SW13
Well, that turns out to be complicated... I have to retrieve the
validation predicates for max, min from the model:
...
Any ideas on how this can be done in a *simpler* way?
Personally, I go with writing a 'validateTarget' method and do all the
validations there. The documentation implied you don't need to call
the built-in property-level validation if you don't need it, but if
I'm wrong about that then I'd just remove the validation constraints
from the entity in the model.
_______________________________________________
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