: DateUtilities for ActionForms?
What are you talking about? I assume you mean the java.util.Date
class. This class is anything but deprecated, it is the de facto method
of storing a date in Java. The reason it has a lot of deprecated methods
and constructors is that in 1.2 the class
nasty way!) for
nanoseconds...
-Original Message-
From: Mark Galbreath [mailto:[EMAIL PROTECTED]
Sent: Monday, 2 June 2003 22:06
To: 'Struts Users Mailing List'
Subject: RE: DateUtilities for ActionForms?
java.sql.Date is a subclass of java.util.Date (as is java.sql.TimeStamp) and
as far
Mailing List'
Subject: RE: DateUtilities for ActionForms?
java.sql.Date is a subclass of java.util.Date (as is java.sql.TimeStamp) and
as far as I can see, is the only reason for the latter's existence. As
David Flannigan points out in Java In A Nutshell, 4th Ed (O'Reilly 2002),
p. 654: Since Java
java.util.Date exists simply to *store* dates, the calendar class and
the dateFormat class exist to *manipulate* dates. java.sql.Date exists
because SQL has different conventions for storing a date than the JVM.
The Java API docs for java.util.Date explain the deprecated methods.
Prior to JDK
[EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
Date: Fri, 30 May 2003 09:18:18 -0400
I wrote a simple conversion method and pass the Strings through - no hassle
at all. Given
: Mark Galbreath [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
Date: Fri, 30 May 2003 09:18:18 -0400
I wrote a simple conversion method and pass the Strings through - no
hassle
Mailing List [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
Date: Fri, 30 May 2003 09:18:18 -0400
I wrote a simple conversion method and pass the Strings through - no
hassle
at all. Given the String Jan 1, 2003:
Calendar date = getDate
are kicking my butt.
---
Thanks...
Mick Knutson
---
From: Mark Galbreath [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
Date: Sat, 31 May 2003 11:32:53 -0400
java.util.Calendar
Nice utils, Ted! Thanks for sharing.
-Original Message-
From: Ted Husted [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 12:07 PM
To: Struts Users Mailing List
Subject: Re: DateUtilities for ActionForms?
I started a helper class here:
http://cvs.sourceforge.net/cgi-bin
Thanks for sharing. I am working on this right now...
---
Thanks...
Mick Knutson
---
From: Ted Husted [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Subject: Re: DateUtilities for ActionForms?
Date: Sat, 31 May 2003 12
Post the relevant code and let's see what we can do...
Mark
-Original Message-
From: Mick Knutson [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 12:12 PM
To: [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
Then why are the months hard-coded?
I am really just
Here is my JSP:
tr
tdbean:message key=alert.endingDate//td
tdhtml:text property=endingDate size=32 maxlength=32 //td
/tr
My DynaForm declaration:
-===
form-bean name=alertForm
dynamic=true
try changing
form-property name=endingDate type=java.util.Date /
to
form-property name=endingDate type=java.sql.Date /
Mark
-Original Message-
From: Mick Knutson [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 12:35 PM
To: [EMAIL PROTECTED]
Subject: RE: DateUtilities
.
HTH.
Gareth.
Mick Knutson wrote:
Is there already a set of DateUtilities for ActionForms?
I am finding myself converting to and from Strings and also
reformating my Dates to and from my DB.
I am using EntityBeans and ValueObjects with my ActionForms, so to
keep the types in synch, it seems I
: Mark Galbreath [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
Date: Sat, 31 May 2003 13:07:43 -0400
try changing
form-property name=endingDate type=java.util.Date /
to
form
[EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Subject: Re: DateUtilities for ActionForms?
Date: Sat, 31 May 2003 18:23:27 +0100
Mick,
Have you tried using the BeanUtils converters. From the docs:
*org.apache.commons.beanutils.locale.converters.DateLocaleConverter
*
Standard
Yes, you would have to change all references in any class.
-Original Message-
From: Mick Knutson [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 1:25 PM
To: [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
I will try that, but would I also have to change my
]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
Date: Sat, 31 May 2003 13:34:05 -0400
Yes, you would have to change all references in any class.
-Original Message-
From: Mick Knutson [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 1:25 PM
: Saturday, May 31, 2003 1:41 PM
To: [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
I just tried again, and get the BeanUtils.populate error. No other
stacktrace. I really hate that. It tells me nothing about the actual error,
and it seems to be somewhere in the Controller I think
: DateUtilities for ActionForms?
Date: Sat, 31 May 2003 13:46:53 -0400
I'd advise that, since you are under a deadline here, that you change the
type from Date to String and do the conversions in your Action class. At
least until we can figure out what is wrong. And I would use Calendar, not
Date
I feel your pain, dude.
-Original Message-
From: Mick Knutson [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 1:52 PM
To: [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
I guess that is what I will have to do and re-visit this later. I _do_ thank
you for your help
PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Subject: Re: DateUtilities for ActionForms?
Date: Sat, 31 May 2003 18:23:27 +0100
Mick,
Have you tried using the BeanUtils converters. From the docs
for ActionForms?
Date: Sat, 31 May 2003 13:56:21 -0400
I feel your pain, dude.
-Original Message-
From: Mick Knutson [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 1:52 PM
To: [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
I guess that is what I will have to do and re
Drink more microbrew.
-Original Message-
From: Mick Knutson [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 2:00 PM
To: [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
Thanks.
I can't wait till the pain is over and the euphoric numbing takes over
Why are you guys continuing to advocate the use of a deprecated class? Look
at the API!
Mark
-Original Message-
From: Gareth Andrew [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 1:59 PM
To: Struts Users Mailing List
Subject: Re: DateUtilities for ActionForms?
If you want
Mailing List' [EMAIL PROTECTED]
Subject: RE: DateUtilities for ActionForms?
Date: Sat, 31 May 2003 14:01:45 -0400
Drink more microbrew.
-Original Message-
From: Mick Knutson [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 2:00 PM
To: [EMAIL PROTECTED]
Subject: RE: DateUtilities
Message-
From: Gareth Andrew [mailto:[EMAIL PROTECTED]
Sent: Saturday, May 31, 2003 1:59 PM
To: Struts Users Mailing List
Subject: Re: DateUtilities for ActionForms?
If you want to use Locale aware conversions perhaps you should be using
LocaleBeanUtils rather than BeanUtils. You should
JDK 1.4.
Mark
-Original Message-
From: Mick Knutson [mailto:[EMAIL PROTECTED]
Sent: Friday, May 30, 2003 4:09 AM
To: [EMAIL PROTECTED]
Subject: DateUtilities for ActionForms?
Is there already a set of DateUtilities for ActionForms?
I am finding myself converting to and from Strings
Is there already a set of DateUtilities for ActionForms?
I am finding myself converting to and from Strings and also reformating my
Dates to and from my DB.
I am using EntityBeans and ValueObjects with my ActionForms, so to keep the
types in synch, it seems I have to do serious conversion all
29 matches
Mail list logo