public abstract class

Status.TimerOrStopwatchPart

extends Status.Part

 java.lang.Object

androidx.wear.ongoing.Status.Part

↳androidx.wear.ongoing.Status.TimerOrStopwatchPart

Subclasses:

Status.TimerPart, Status.StopwatchPart

Overview

Base class for Status.TimerPart and Status.StopwatchPart, defines the getters but can't be created directly, create one of those instead.

Summary

Methods
public booleanequals(java.lang.Object obj)

public longgetNextChangeTimeMillis(long fromTimeMillis)

See TimeDependentText.getNextChangeTimeMillis(long)

public longgetPausedAtMillis()

public java.lang.CharSequencegetText(Context context, long timeNowMillis)

See TimeDependentText.getText(Context, long)

public longgetTimeZeroMillis()

public longgetTotalDurationMillis()

public inthashCode()

public booleanhasTotalDuration()

Determines if this has a total duration set.

public booleanisCountDown()

public booleanisPaused()

Determines if this Timer or Stopwatch is paused.

from java.lang.Objectclone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait

Methods

public long getTimeZeroMillis()

Returns:

the time at which this Timer or Stopwatch will display 0, will usually be in the past for a stopwatch and in the future for timers.

public boolean isCountDown()

Returns:

false if this is a stopwatch or true if this is a timer.

public boolean isPaused()

Determines if this Timer or Stopwatch is paused. i.e. the display representation will not change over time.

Returns:

true if this is paused, false if it's running.

public long getPausedAtMillis()

Returns:

the timestamp of the time when this was paused. Use Status.TimerOrStopwatchPart.isPaused() to determine if this is paused or not.

public boolean hasTotalDuration()

Determines if this has a total duration set.

Returns:

true if this the total duration was set, false if not.

public long getTotalDurationMillis()

Returns:

the total duration of this timer/stopwatch, if set. Use Status.TimerOrStopwatchPart.hasTotalDuration() to determine if this has a duration set.

public int hashCode()

public boolean equals(java.lang.Object obj)

public java.lang.CharSequence getText(Context context, long timeNowMillis)

See TimeDependentText.getText(Context, long)

public long getNextChangeTimeMillis(long fromTimeMillis)

See TimeDependentText.getNextChangeTimeMillis(long)