public static OffsetTime from (TemporalAccessor temporal)

Obtains an instance of OffsetTime from a temporal object.

This obtains an offset 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 OffsetTime.

The conversion extracts and combines the ZoneOffset and the LocalTime from the temporal object. 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, OffsetTime::from.

Parameters:
temporal    the temporal object to convert, not null

Returns:  the offset time, not null

Exceptions:
DateTimeException    if unable to convert to an OffsetTime