Skip to content

Instantly share code, notes, and snippets.

@moea
Created January 20, 2016 11:51
Show Gist options
  • Save moea/b4b4520c27a0b033f7f9 to your computer and use it in GitHub Desktop.
Save moea/b4b4520c27a0b033f7f9 to your computer and use it in GitHub Desktop.
package io.nervous.alarmtest;
import android.content.Context;
import android.content.Intent;
import android.support.v4.content.WakefulBroadcastReceiver;
public class AlarmWakefulReceiver extends WakefulBroadcastReceiver {
@Override
public void onReceive(Context context, Intent intent) {
Intent service = new Intent(context, AlarmIntentService.class);
startWakefulService(context, service);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment