What class is DateTime? I'm not familiar with it and I can't find it. I know java.util.Date, java.sql.Date, java.sql.Time, java.sql.Timestamp but not DateTime
"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.
Wouter Oet wrote:What class is DateTime? I'm not familiar with it and I can't find it. I know java.util.Date, java.sql.Date, java.sql.Time, java.sql.Timestamp but not DateTime
I was having a similar problem. I searched the JavaDocs but couldn't find a DateTime class...
SCJA
When I die, I want people to look at me and say "Yeah, he might have been crazy, but that was one zarkin frood that knew where his towel was."
I don't know Joda Time, but here's what I see in that code. You have one object which is a kind of date. You assign the São Paulo time zone to it. Next you create a second object which is also a kind of date, but you don't assign the São Paulo time zone to it. Therefore its time zone is whatever your default time zone is, or whatever the default time zone for a Joda object is. Not the same time zone? Then you shouldn't be surprised that they appear differently.