Type Property

localTimeZone

An object that tracks the current system time zone.

Declaration

@property(class, readonly, copy) NSTimeZone *localTimeZone;

Discussion

Use this property when you want an object that always reflects the current system time zone. Contrast this behavior with that of the systemTimeZone class property, which has its value cached until you manually clear it by calling the resetSystemTimeZone method.

Although the time zone obtained here automatically updates with the system, it provides no indication when system settings change. To receive notification of time zone changes, add an observer to the NSSystemTimeZoneDidChangeNotification notification by using the addObserver:selector:name:object:.

See Also

Working with System Time Zones

systemTimeZone

The time zone currently used by the system.

+ resetSystemTimeZone

Clears any time zone value cached for the systemTimeZone property.

defaultTimeZone

The default time zone for the current app.