• 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: model.validateKey intercepted on null?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: model.validateKey intercepted on null?


  • Subject: Re: model.validateKey intercepted on null?
  • From: Kieran Kelleher <email@hidden>
  • Date: Fri, 30 Jan 2009 10:02:24 -0500

FWIW, the way I handle this is:

1) Set the EOModel to Allow Null.

2) Set the database to NOT NULL which guarantees not saving nulls.

3) Handle the nulls in your own validate methods as you wish to do.

- this works.

HTH, Kieran

On Jan 30, 2009, at 9:38 AM, WebObjects - Anazys wrote:

Hi all,

I have the same problem that describes in this old mail : a NullPropertyException (from ERXValidationException) is thrown instead of using my validateKey methods.
Has somebody found a solution to that without changing the model ?


Thanks.
Cedric

Le 2 juin 08 à 17:35, Rams a écrit :

Hi everyone,

I have a model object using the WonderEntity template and my validateKey methods are being intercepted higher up with a NullPropertyException (ERXValidationException). I'd like to handle the null values myself and throw a localized exception message, but my validateKey method never gets called if the value is null. Does anyone know how I can catch that null value myself?

Thank you! :-) _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden

_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden

_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Re: model.validateKey intercepted on null? (From: WebObjects - Anazys <email@hidden>)

  • Prev by Date: Re: model.validateKey intercepted on null?
  • Next by Date: Re: Prefetching?
  • Previous by thread: Re: model.validateKey intercepted on null?
  • Next by thread: Re: model.validateKey intercepted on null?
  • Index(es):
    • Date
    • Thread