• 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: What is the best way to handle invalid values from a WOTextField?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: What is the best way to handle invalid values from a WOTextField?


  • Subject: Re: What is the best way to handle invalid values from a WOTextField?
  • From: Chuck Hill <email@hidden>
  • Date: Tue, 17 Jun 2008 10:32:18 -0700


On Jun 17, 2008, at 10:04 AM, Ralf Schuchardt wrote:

Hi,

in the past (until WO 5.4) I often have used a WOTextField with a formatter to prevent errors like this:

"java.lang.IllegalArgumentException: While trying to invoke the set method "public void com.cx.harow.eos._ArztFolgedokLeistung $StorageClass.setAnzahl(java.lang.Short)" on an object of type com.cx.harow.arzt.dokumente.ArztFolgedokumentationContext $TempFolgedokLeistung we received an argument of type java.lang.String. This often happens if you forget to use a formatter."

When a value was invalid the formatter did not set an invalid value in my objects.

Now, in WO 5.4 this is no longer true. When the formatter fails to parse a string it still gets pushed into the target object. As this is documented is must somehow be considered "expected" behavior. Unfortunately this breaks all our apps, as no class handles those invalid strings.

Whoa! Where is this documented? I also depend on this.


Chuck


What is the best way to restore a sane behavior in WO 5.4? Do I have to write validate...-Methods for every class, that gets formatted values and drop those strings? Does WONDER have a fix for this?

Thanks,
Ralf

_______________________________________________
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


--

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects






_______________________________________________
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: What is the best way to handle invalid values from a WOTextField?
      • From: Don Lindsay <email@hidden>
    • Re: What is the best way to handle invalid values from a WOTextField?
      • From: Ralf Schuchardt <email@hidden>
References: 
 >What is the best way to handle invalid values from a WOTextField? (From: Ralf Schuchardt <email@hidden>)

  • Prev by Date: Re: WebObjects 5.4 on Linux (Red Hat Enterprise)
  • Next by Date: Re: build.xml
  • Previous by thread: What is the best way to handle invalid values from a WOTextField?
  • Next by thread: Re: What is the best way to handle invalid values from a WOTextField?
  • Index(es):
    • Date
    • Thread