RE: [slightly OT] Time zone strategies

2002-12-02 Thread Ryan Olson
Well, that's the approach I'd taken originally, but I found two problems with it: 1) I didn't like how that approach mixes the presentation layer into the business layer (ie, my data access objects shouldn't care what timezone the user is in) 2) I don't necessarily know ahead of time (ie, when

RE: [slightly OT] Time zone strategies

2002-12-02 Thread Hajratwala, Nayan (N.)
I didn't delve too much into the details of your current approach, but couldn't you do this fairly easily using the Calendar class... Date fromDb = ResultSet.getDate(...); Calendar cal = Calendar.getInstance(user's TimeZone, optionally user's Locale); cal.setTime(fromDb); Now you can ma