LocalTime

public abstract class LocalTime extends Object
implements Parcelable Comparable<LocalTime>

Represents a local time with just hours and minutes. This class is based on the LocalTime class (available on SDK 26 and higher).

Inherited Constant Summary

Public Constructor Summary

Public Method Summary

int
compareTo(LocalTime compare)
abstract int
getHours()
Returns the hours in 24 hour format (0 <= return value < 24).
abstract int
getMinutes()
Returns the minutes (0 <= return value < 60).
static LocalTime
newInstance(int hours, int minutes)
Returns a LocalTime instance given the hours and minutes.

Inherited Method Summary

Public Constructors

public LocalTime ()

Public Methods

public int compareTo (LocalTime compare)

Parameters
compare

public abstract int getHours ()

Returns the hours in 24 hour format (0 <= return value < 24).

public abstract int getMinutes ()

Returns the minutes (0 <= return value < 60).

public static LocalTime newInstance (int hours, int minutes)

Returns a LocalTime instance given the hours and minutes.

Parameters
hours
minutes
Throws
IllegalArgumentException If parameters are out of range: 0 <= hours < 24, 0 <= minutes < 60, i.e 00:00 to 23:59.

发送以下问题的反馈:

此网页
Places SDK for Android