Language

IChronoZonedDateTime.From(ITemporalAccessor) Method

Definition

Obtains an instance of ChronoZonedDateTime from a temporal object.

[Android.Runtime.Register("from", "(Ljava/time/temporal/TemporalAccessor;)Ljava/time/chrono/ChronoZonedDateTime;", "", ApiSince=26)]
public static Java.Time.Chrono.IChronoZonedDateTime? From(Java.Time.Temporal.ITemporalAccessor? temporal);
[<Android.Runtime.Register("from", "(Ljava/time/temporal/TemporalAccessor;)Ljava/time/chrono/ChronoZonedDateTime;", "", ApiSince=26)>]
static member From : Java.Time.Temporal.ITemporalAccessor -> Java.Time.Chrono.IChronoZonedDateTime

Parameters

temporal
ITemporalAccessor

the temporal object to convert, not null

Returns

the date-time, not null

Attributes

Remarks

Obtains an instance of ChronoZonedDateTime from a temporal object. This creates a zoned date-time based on the specified temporal. A TemporalAccessor represents an arbitrary set of date and time information, which this factory converts to an instance of ChronoZonedDateTime. The conversion extracts and combines the chronology, date, time and zone from the temporal object. The behavior is equivalent to using Chronology.zonedDateTime(TemporalAccessor) with the extracted chronology. Implementations are permitted to perform optimizations such as accessing those fields that are equivalent to the relevant objects. This method matches the signature of the functional interface TemporalQuery allowing it to be used as a query via method reference, ChronoZonedDateTime::from.

Java reference for java.time.chrono.ChronoZonedDateTime.from.

Applies to