Subject: [xsl] How to date type conversion between xml and Java From: Jack Bush <netbeansfan@xxxxxxxxxxxx> Date: Fri, 13 Aug 2010 07:17:57 -0700 (PDT) |
Hi All, B I need some advice on how to store the followingB dateB value from a xhtml document using JPA: cB B B <strong>Time:</strong> B B B B B <time>13/08/2010 00:10:19 am</time> B </p> B There is no problem retrieving this value using XPath query. However, the value returned is of type string yet JPA (futureStock.setCollectionTime()) expects type java.util.Date such asB the following code snippet: B B B B org.jdom.Element collection_time = ((org.jdom.Element)time_element).getChild("time"); B B B futureStock.setCollectionTime(collection_time.getTextNormalize()); B I would like to be in a position to retrieve both date and time separately at a later stage. B Any idea on how to overcome this issue? Thanks a lot, Jack-<p> c P.S. Apologies for asking Java type of question in an xslt forum but thought I try anyway since I am developing Java EE 5 development which consists of both technologies.
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Best approach for writing, Michael Kay | Thread | [no subject], Unknown |
Re: [xsl] Best approach for writing, Sam Byland | Date | Re: [xsl] Best approach for writing, Michael Kay |
Month |