Freigeben über


DateFormat.TimeZone Property

Definition

Gets the time zone. -or- Sets the time zone for the calendar of this DateFormat object.

public virtual Java.Util.TimeZone TimeZone { [Android.Runtime.Register("getTimeZone", "()Ljava/util/TimeZone;", "GetGetTimeZoneHandler")] get; [Android.Runtime.Register("setTimeZone", "(Ljava/util/TimeZone;)V", "GetSetTimeZone_Ljava_util_TimeZone_Handler")] set; }
[<get: Android.Runtime.Register("getTimeZone", "()Ljava/util/TimeZone;", "GetGetTimeZoneHandler")>]
[<set: Android.Runtime.Register("setTimeZone", "(Ljava/util/TimeZone;)V", "GetSetTimeZone_Ljava_util_TimeZone_Handler")>]
member this.TimeZone : Java.Util.TimeZone with get, set

Property Value

the time zone associated with the calendar of DateFormat.

Attributes

Remarks

Property getter documentation:

Gets the time zone. This method is equivalent to the following call. <blockquote>

{@code
            getCalendar().getTimeZone()
            }

</blockquote>

Java documentation for java.text.DateFormat.getTimeZone().

Property setter documentation:

Sets the time zone for the calendar of this DateFormat object. This method is equivalent to the following call. <blockquote>

{@code
            getCalendar().setTimeZone(zone)
            }

</blockquote>

The TimeZone set by this method is overwritten by a #setCalendar(java.util.Calendar) setCalendar call.

The TimeZone set by this method may be overwritten as a result of a call to the parse method.

Java documentation for java.text.DateFormat.setTimeZone(java.util.TimeZone).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to