Aracılığıyla paylaş


Duration.ToMillisPart Method

Definition

Extracts the number of milliseconds part of the duration.

[Android.Runtime.Register("toMillisPart", "()I", "", ApiSince=31)]
public int ToMillisPart ();
[<Android.Runtime.Register("toMillisPart", "()I", "", ApiSince=31)>]
member this.ToMillisPart : unit -> int

Returns

the number of milliseconds part of the duration.

Attributes

Remarks

Extracts the number of milliseconds part of the duration.

This returns the milliseconds part by dividing the number of nanoseconds by 1,000,000. The length of the duration is stored using two fields - seconds and nanoseconds. The nanoseconds part is a value from 0 to 999,999,999 that is an adjustment to the length in seconds. The total duration is defined by calling #getNano() and #getSeconds().

This instance is immutable and unaffected by this method call.

Added in 9.

Java documentation for java.time.Duration.toMillisPart().

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