Package com.aurelienpierre.sioul
Class EventReceiver
java.lang.Object
android.content.BroadcastReceiver
com.aurelienpierre.sioul.EventReceiver
The events' reminders (EventAlarms): at a reminder's time, Rust is asked
what to say (crates/sioul-app/src/eventalarms.rs) on a thread of its own,
the broadcast held open meanwhile (goAsync), as for the doses
(DoseReceiver). Past 45 seconds the broadcast is let go before Android
takes Sioul for hung, and the words given with the list are said: never
nothing; Rust's answer, if it comes, replaces them or takes them away.
Also the phone's own moments: started, Sioul updated, the time or the zone
changed, "Alarms & reminders" allowed again: the alarms given again from
the list kept, then Rust asked for the list as it is now; and once a day.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final classOne broadcast: answered in time, or let go at the deadline and answered after.Nested classes/interfaces inherited from class android.content.BroadcastReceiver
BroadcastReceiver.PendingResult -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidRust asked for the list as it is now, on a thread of its own, the broadcast held open.private static voidRust's decision: shown already (by Rust, throughEventAlarms.show(android.content.Context, java.lang.String)); held now, asked again at `again_at`; or nothing (moved, cancelled, told, too late).voidprivate voidA reminder's time: Rust's decision, or the words kept at the deadline.Methods inherited from class android.content.BroadcastReceiver
abortBroadcast, clearAbortBroadcast, getAbortBroadcast, getDebugUnregister, getResultCode, getResultData, getResultExtras, getSentFromPackage, getSentFromUid, goAsync, isInitialStickyBroadcast, isOrderedBroadcast, peekService, setDebugUnregister, setOrderedHint, setResult, setResultCode, setResultData, setResultExtras
-
Field Details
-
DEADLINE_MS
- See Also:
-
-
Constructor Details
-
EventReceiver
public EventReceiver()
-
-
Method Details
-
onReceive
- Specified by:
onReceivein classBroadcastReceiver
-
ring
A reminder's time: Rust's decision, or the words kept at the deadline. -
ask
Rust asked for the list as it is now, on a thread of its own, the broadcast held open. -
decided
Rust's decision: shown already (by Rust, throughEventAlarms.show(android.content.Context, java.lang.String)); held now, asked again at `again_at`; or nothing (moved, cancelled, told, too late). No answer at all: the words kept, rather than nothing.
-