• 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: Postponed validation possible?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Postponed validation possible?


  • Subject: Re: Postponed validation possible?
  • From: Anjo Krank <email@hidden>
  • Date: Wed, 11 Nov 2009 23:38:57 +0100

>>> Because then the user loses what they typed which can sometimes be annoying (e.g., if it's too long a string etc)
>>
>> As i said: then push the invalid value. This is what ERXValidation does.
>
> And if the value's of the wrong type or can't be coerced?

            if (eo instanceof EOEnterpriseObject) {
                // the exception is coming from EREnterpriseObject
                // WE PUSH THE WRONG VALUE INTO THE EO ANYWAY!
                if (pushChanges)  {
                    try {
                        ((EOEnterpriseObject)eo).takeValueForKeyPath(value, key);
                    } catch(NSKeyValueCoding.UnknownKeyException  ex) {
                        // AK: as we could have custom components that have non-existant keys
                        // we of course can't push a value, so we discard the resulting exception
                    } catch(Exception ex) {
                        log.error("Can't push value to key '" + key + "': " + value, ex);
                    }
                }

Cheers, Anjo

 _______________________________________________
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

  • Follow-Ups:
    • Re: Postponed validation possible?
      • From: Riccardo De Menna <email@hidden>
    • Re: Postponed validation possible?
      • From: Ramsey Lee Gurley <email@hidden>
    • Re: Postponed validation possible?
      • From: Riccardo De Menna <email@hidden>
References: 
 >Postponed validation possible? (From: Riccardo De Menna <email@hidden>)
 >Re: Postponed validation possible? (From: Lachlan Deck <email@hidden>)
 >Re: Postponed validation possible? (From: Anjo Krank <email@hidden>)
 >Re: Postponed validation possible? (From: Lachlan Deck <email@hidden>)
 >Re: Postponed validation possible? (From: Anjo Krank <email@hidden>)
 >Re: Postponed validation possible? (From: Lachlan Deck <email@hidden>)

  • Prev by Date: Owns destination implies mandatory?
  • Next by Date: Owns destination implies mandatory?
  • Previous by thread: Re: Owns destination implies mandatory?
  • Next by thread: Re: Postponed validation possible?
  • Index(es):
    • Date
    • Thread