public class NacWakeupProcess extends java.lang.Object implements java.lang.Runnable, NacTextToSpeech.OnSpeakingListener
| Modifier and Type | Class and Description |
|---|---|
static interface |
NacWakeupProcess.OnAutoDismissListener
Auto dismiss listener interface.
|
| Constructor and Description |
|---|
NacWakeupProcess(android.content.Context context,
NacAlarm alarm) |
| Modifier and Type | Method and Description |
|---|---|
void |
cleanup()
Cleanup various alarm objects.
|
boolean |
equals(NacWakeupProcess process)
Check if one wakeup process equals another.
|
NacAlarm |
getAlarm() |
void |
onDoneSpeaking(NacTextToSpeech tts,
NacAudio.Attributes attrs)
Called when speech engine is done speaking.
|
void |
onStartSpeaking(NacTextToSpeech tts,
NacAudio.Attributes attrs)
Called when speech engine has started speaking.
|
void |
run()
Automatically dismiss the alarm.
|
void |
setOnAutoDismissListener(NacWakeupProcess.OnAutoDismissListener listener)
Set the auto dismiss listener.
|
void |
start()
Start the wake up process.
|
void |
stop()
Stop the wake up process.
|
void |
vibrate()
Vibrate the phone repeatedly until the alarm is dismissed.
|
void |
waitForAutoDismiss()
Wait in the background until the activity needs to auto dismiss the
alarm.
|
public NacWakeupProcess(android.content.Context context,
NacAlarm alarm)
public void cleanup()
public boolean equals(NacWakeupProcess process)
public NacAlarm getAlarm()
public void onDoneSpeaking(NacTextToSpeech tts, NacAudio.Attributes attrs)
NacTextToSpeech.OnSpeakingListeneronDoneSpeaking in interface NacTextToSpeech.OnSpeakingListenerpublic void onStartSpeaking(NacTextToSpeech tts, NacAudio.Attributes attrs)
NacTextToSpeech.OnSpeakingListeneronStartSpeaking in interface NacTextToSpeech.OnSpeakingListenerpublic void run()
run in interface java.lang.Runnablepublic void setOnAutoDismissListener(NacWakeupProcess.OnAutoDismissListener listener)
public void start()
public void stop()
public void vibrate()
public void waitForAutoDismiss()