Re: validateForInsert
Re: validateForInsert
- Subject: Re: validateForInsert
- From: Chuck Hill <email@hidden>
- Date: Thu, 04 Sep 2003 10:37:43 -0700
- Organization: Global Village Consulting, Inc.
Once again this falls in the category of obfuscated documentation.
Perhaps the documentation was written by Philosophy students wishing
us to exercise our powers of deductive reasoning? ;-)
It is called at the same point that validateForSave() is called. You
can find some mention of this here:
http://developer.apple.com/documentation/WebObjects/Reference/API/com/webobjects/eocontrol/EOValidation.html
"The method validateForSave is the generic validation method for when
an object is written to the external store. The default
implementations of validateForInsert, validateForUpdate both invoke it."
"Confirms that the receiver can be inserted in its current state,
throwing an NSValidation.ValidationException if it can't.
EOCustomObject's implementation simply invokes validateForSave."
There is a bit more here,
http://developer.apple.com/documentation/WebObjects/Enterprise_Objects/BusinessLogic/chapter_4_section_4.html
This can be affected to some degree by the EOEditingContext.Delegate
method editingContextShouldValidateChanges()
Chuck
Jonathan Rochkind wrote:
Is the validateForInsert method called on an EO at the point it is
inserted, or at the point saveChanges is called when pending inserted
EOs exist? Or is this behavior effected by any settings, delegates,
configuration, etc?
Thanks if anyone knows about this stuff,
--Jonathan
--
Chuck Hill email@hidden
Global Village Consulting Inc. http://www.global-village.net
Progress is the mother of all problems.
- G. K. Chesterton
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.