Adjacent Files

Project Info

. > app > src > main > java > james > alarmio > services > SleepReminderService.java

refreshState

Type: public void

Refresh the state of the sleepy stuff. This will either show a notification if a notification should be shown, or stop the service if it shouldn’t.

getSleepyAlarm

Type: @Nullable public static AlarmData

Get a sleepy alarm. Well, get the next alarm that should trigger a sleep alert.

Parameter Name Description
alarmio The active Application instance.

Returned Value: The next AlarmData that should trigger a sleep alert, or null if there isn’t one.

getNextWakeAlarm

Type: @Nullable public static AlarmData

Get the next scheduled AlarmData that will ring.

Parameter Name Description
alarmio The active Application instance.

Returned Value: The next AlarmData that will wake the user up.

refreshSleepTime

Type: public static void

To be called whenever an alarm is changed, might change, or when time might have unexpectedly leaped forwards. This will start the service if there is a sleepy alarm present.

Parameter Name Description
context An active context instance.
This site may do shady things with cookies and stuff because it's evil. Please don't read my privacy policy. close