How can I determine if the east coast is currently using EST or EDT using the iPhone SDK?
I am aware of the NSTimeZone class and I attempted the following but it did not work, the result is "East coast is NOT on DT" which it currently is. This leads me to believe that isDayLightSavingTime simply checks whether its being passed an ST or DT value rather than determining if EST should currently be EDT
NSTimeZone *easternTimeZone = [NSTimeZone timeZoneWithAbbreviation:@"EST"];
if ([easternTimeZone isDaylightSavingTime]) {
NSLog(@"East coast is NOT on DT");
} else {
NSLog(@"East coast is on DT");
}
UPDATE:
The end goal is I need to be able to calculate the correct current time in the eastern timezone, taking into account whether they are currently observing daylight savings time.
UPDATE 2:
Interesting result, when I change
NSTimeZone *easternTimeZone = [NSTimeZone timeZoneWithAbbreviation:@"EST"];
to
NSTimeZone *easternTimeZone = [NSTimeZone timeZoneWithAbbreviation:@"EDT"];
it still returns "East Coast is NOT on DT"