This content has been marked as final. Show 4 replies
You've got all that code which you say demonstrates the problem, but you don't show us the output. So that's the first thing you should do.
It would also be useful to see what exactly your default timezone is, the one you say is returning the wrong information.
I tried your test code (after fixing the errors). Here's the output I got after I changed my Windows 7 machine's time zone to UTC + 02:00 Istanbul:
Time zone is seto to Istanbul
Getting system time.....:0006
Getting system time.....:0006-> This is the correct value
That looks okay to me... but you didn't say what you were expecting to see.
By the way I'm using Java 7. Perhaps you're using an old version of Java 6 which doesn't have that Istanbul time zone. (Although that sounds unlikely to me.) Check out this page: Timezone Updater Tool.
Moderator action: Moved to New to Java. Connection with Generics: zero.