Re: [Wicket-user] TypeValidator doesn't check if a date is valid

2005-08-26 Thread Phil Kulak
haha, I stand corrected. :) On 8/26/05, Eelco Hillenius <[EMAIL PROTECTED]> wrote: > Actually, it's both. It's on DateFormat, as that is what we use in > Wicket. However DateFormat uses an instance of Calendar: > > public void setLenient(boolean lenient) > { > calendar.setLenient(

Re: [Wicket-user] TypeValidator doesn't check if a date is valid

2005-08-26 Thread Eelco Hillenius
Actually, it's both. It's on DateFormat, as that is what we use in Wicket. However DateFormat uses an instance of Calendar: public void setLenient(boolean lenient) { calendar.setLenient(lenient); } :) Sorry, couldn't resist being a smart ass. Eelco

Re: [Wicket-user] TypeValidator doesn't check if a date is valid

2005-08-26 Thread Phil Kulak
No, it's DateFormat.setLenient(boolean lenient). On 8/26/05, Nick Heudecker <[EMAIL PROTECTED]> wrote: > I think the leniency is in Calendar, not DateFormat. > > On 8/25/05, Eelco Hillenius <[EMAIL PROTECTED]> wrote: > > That's probably the lenient feature of DateFormat. Thought that was > > off

Re: [Wicket-user] TypeValidator doesn't check if a date is valid

2005-08-26 Thread Nick Heudecker
I think the leniency is in Calendar, not DateFormat. On 8/25/05, Eelco Hillenius <[EMAIL PROTECTED]> wrote: > That's probably the lenient feature of DateFormat. Thought that was > off by default. Could you open an issue please? > > Eelco > > On 8/25/05, Johannes Fahrenkrug <[EMAIL PROTECTED]> wr

Re: [Wicket-user] TypeValidator doesn't check if a date is valid

2005-08-26 Thread Johannes Fahrenkrug
Eelco, I opened issue number 1273827 for this. - Johannes Eelco Hillenius wrote: That's probably the lenient feature of DateFormat. Thought that was off by default. Could you open an issue please? Eelco On 8/25/05, Johannes Fahrenkrug <[EMAIL PROTECTED]> wrote: Ok, new insights on this

Re: [Wicket-user] TypeValidator doesn't check if a date is valid

2005-08-25 Thread Eelco Hillenius
That's probably the lenient feature of DateFormat. Thought that was off by default. Could you open an issue please? Eelco On 8/25/05, Johannes Fahrenkrug <[EMAIL PROTECTED]> wrote: > Ok, new insights on this issue: the date automatically gets corrected... > of course because the casting of the st

Re: [Wicket-user] TypeValidator doesn't check if a date is valid

2005-08-25 Thread Johannes Fahrenkrug
Ok, new insights on this issue: the date automatically gets corrected... of course because the casting of the string to the Java date object does that... the question remains if it makes sense to auto-correct the date or if any invalid date should raise an error, informing the user that somet

[Wicket-user] TypeValidator doesn't check if a date is valid

2005-08-25 Thread Johannes Fahrenkrug
Hi, shouldn't the TextField, when you add a TypeValidator of type Date to it, check if the entered date is valid? I can enter the 31st of February, or even the 32nd. And I have to set the Locale for the whole session in order for it to accept the German date format. When I only pass a new Loc