Re: nothing archived...

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: nothing archived...

jodastephen
A user from Nabble just subscribed, so perhaps that was you?
Stephen

Benoit Xhenseval wrote:

> Hi
>
>  
>
> It seems that SourceForge has not been archiving anything since June 11…
>
> http://sourceforge.net/mailarchive/forum.php?forum_name=joda-interest&max_rows=25&style=ultimate&viewmonth=200806 
> <http://sourceforge.net/mailarchive/forum.php?forum_name=joda-interest&max_rows=25&style=ultimate&viewmonth=200806>
>
>  
>
> Stephen, could I suggest that you create an account with www.nabble.com
> <http://www.nabble.com> ? (just need to accept subscription for a given
> user)
>
> The maillist is then archived online in a “proper” system…
>
>  
>
> I’m not affiliated with Nabble, simply a happy user!
>
>  
>
> Thanks!
>
>  
>
> Benoit.
>
>  
>
> ------------------------------
>
> IMPORTANT NOTICE
>
> This communication contains information that is considered confidential
> and may also be privileged . It is for the exclusive use of the intended
> recipient(s). If you are not the intended recipient(s) please note that
> any form of distribution, copying or use of this communication or the
> information in it is strictly prohibited and may be unlawful. If you
> have received this communication in error please return it to the sender
> and delete the original.
>
>  
>
>
> ------------------------------------------------------------------------
>
> -------------------------------------------------------------------------
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Joda-interest mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/joda-interest

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Joda-interest mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/joda-interest
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: nothing archived...

BenoitX
Administrator
This post has NOT been accepted by the mailing list yet.
Hi Stephen,

Yes it was me. Given the current problems with SF, I took the liberty to start a free archive on http://n2.nabble.com

I did not even see my previous post... about TZ and Co:

I need to represent a Time (24h clock) but with a TimeZone.  I am using Joda-time 1.5.

Which entity is the most suited given that I need to store in Oracle via Hibernate and also have some kind of widgets in a Swing application to change that time… (anybody willing to share???)

That time will have to be compared with a Time “now”.

Should I use DateTime? But I do not need the ‘date’…

Many thanks

Best regards from London,



Stephen Colebourne wrote
A user from Nabble just subscribed, so perhaps that was you?
Stephen
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: nothing archived...

BenoitX
Administrator
In reply to this post by jodastephen
Hi Stephen,

Yes it was me. Given the current problems with SF, I took the liberty to start a free archive on http://n2.nabble.com

I did not even see my previous post in the archive or on the list...:

I need to represent a Time (24h clock) but with a TimeZone.  I am using Joda-time 1.5.

Which entity is the most suited given that I need to store in Oracle via Hibernate and also have some kind of widgets in a Swing application to change that time… (anybody willing to share???)

That time will have to be compared with a Time “now”.

Should I use DateTime? But I do not need the ‘date’…
Should I use LocalTime AND a DateTimeZone (in order to create a swing widget to handle both separately).

Many thanks

Best regards from London,

Benoit
Stephen Colebourne wrote
A user from Nabble just subscribed, so perhaps that was you?
Stephen
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: nothing archived...

jodastephen
This is a feature that is in the works for JSR-310. I don't have much
time for Joda-Time these days, so haven't got any immediate intentions
of adding it there.
Stephen

2008/7/4 Benoit Xhenseval <[hidden email]>:

> Do you think it would be a good addition to JODA?
> When scheduling things, it is important in our domain to say "this should
> happen at 14:00 London time"
> We should also be able to compare "Now" with a time including a TZ..
>
> I can see that the combination LocalTime + DateTimeZone might work.
> Comparison with Now could be done:
> DateTime dt = myLocalTime.toDateTimeToday(myDateTimeZone);
> DateTime now = new DateTime();
>
> now.isAfter(dt)...
>
> That would work I believe, but is it the best way?
> Benoit.

> -----Original Message-----
> From: [hidden email] [mailto:[hidden email]] On
> Behalf Of Stephen Colebourne
> Sent: 04 July 2008 10:41
> To: [hidden email]
> Subject: Re: [Joda-interest] nothing archived...
>
> Joda-Time does not have an ideal class for storing this. You can
> either create your own class holding a LocalTime and a DateTimeZone,
> or use a DateTime with a fixed known date (such as 1970-01-01).
>
> You could also subclass BaseDateTime and override the method that is
> called in the constructor that can enforce restrictions (see
> DateMidnight).
> Stephen
>
> 2008/7/3 BenoitX <[hidden email]>:
>> I need to represent a Time (24h clock) but with a TimeZone.  I am using
>> Joda-time 1.5.
>>
>> Which entity is the most suited given that I need to store in Oracle via
>> Hibernate and also have some kind of widgets in a Swing application to
>> change that time. (anybody willing to share???)
>>
>> That time will have to be compared with a Time "now".
>>
>> Should I use DateTime? But I do not need the 'date'.
>> Should I use LocalTime AND a DateTimeZone (in order to create a swing
> widget
>> to handle both separately).

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Joda-interest mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/joda-interest
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

LocalTime and TZ

BenoitX
Administrator
Allow me to put some ideas here...

I can store a LocalTime in my DB (eg 18:00) alongside with a String for the TimeZone "Europe/Brussels"

Is there a way to create a LocalTime using both?
eg
LocalTime ltFromDB (contains 18:00 UTC)
LocalTime lt = new LocalTime(ltFromDB, DateTimeZone.forID("Europe/Brussels"));

When I print lt, I get:18:00 UTC as if it had ignored the timezone in the constructor.

Alternatively, say that I am in London (which I am):
LocalTime now = new LocalTime(), eg 17:55
Say that was coming from the DB

LocalTime asInBxl = new LocalTime(now, DateTimeZone.forID("Europe/Brussels"));

I would expect asInBxl to show me 18:55 but it is still 17:55...

I must have misunderstood something obviously, but it seems that the constructor with a TZ does nothing? Please correct me...

If I do:
DateTime dateTimeTodayBxl = now.toDateTimeToday(DateTimeZone.forID("Europe/Brussels"));

I then get 2008-07-04T17:55:00+02:00 which is what I would expect BUT there is a date that I do not need...

Many thanks

Benoit.

jodastephen wrote
This is a feature that is in the works for JSR-310. I don't have much
time for Joda-Time these days, so haven't got any immediate intentions
of adding it there.
Stephen
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: LocalTime and TZ

jodastephen
The time zone on the LocalTime constructor is used with some of the
other values that can be passed as the first argument (such as DateTime).

You are probably best creating a DateTime from the database, and then
extracting the LocalTime from that.

Stephen


BenoitX wrote:

> Allow me to put some ideas here...
>
> I can store a LocalTime in my DB (eg 18:00) alongside with a String for the
> TimeZone "Europe/Brussels"
>
> Is there a way to create a LocalTime using both?
> eg
> LocalTime ltFromDB (contains 18:00 UTC)
> LocalTime lt = new LocalTime(ltFromDB,
> DateTimeZone.forID("Europe/Brussels"));
>
> When I print lt, I get:18:00 UTC as if it had ignored the timezone in the
> constructor.
>
> Alternatively, say that I am in London (which I am):
> LocalTime now = new LocalTime(), eg 17:55
> Say that was coming from the DB
>
> LocalTime asInBxl = new LocalTime(now,
> DateTimeZone.forID("Europe/Brussels"));
>
> I would expect asInBxl to show me 18:55 but it is still 17:55...
>
> I must have misunderstood something obviously, but it seems that the
> constructor with a TZ does nothing? Please correct me...
>
> If I do:
> DateTime dateTimeTodayBxl =
> now.toDateTimeToday(DateTimeZone.forID("Europe/Brussels"));
>
> I then get 2008-07-04T17:55:00+02:00 which is what I would expect BUT there
> is a date that I do not need...
>
> Many thanks
>
> Benoit.
>
>
> jodastephen wrote:
>> This is a feature that is in the works for JSR-310. I don't have much
>> time for Joda-Time these days, so haven't got any immediate intentions
>> of adding it there.
>> Stephen
>>
>

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Joda-interest mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/joda-interest
Loading...