Here you can find the source of setExact(AlarmManager alarmManger, int type, long triggerAtMillis, PendingIntent operation)
Parameter | Description |
---|---|
alarmManger | a parameter |
type | a parameter |
triggerAtMillis | a parameter |
operation | a parameter |
@SuppressLint("NewApi") public static void setExact(AlarmManager alarmManger, int type, long triggerAtMillis, PendingIntent operation)
//package com.java2s; //License from project: Open Source License import android.annotation.SuppressLint; import android.app.AlarmManager; import android.app.PendingIntent; import android.os.Build; public class Main { @SuppressLint("NewApi") public static void setExact(AlarmManager alarmManger, int type, long triggerAtMillis, PendingIntent operation) { if (Build.VERSION.SDK_INT >= 19) { alarmManger.setExact(type, triggerAtMillis, operation); } else {// w ww. j a v a 2 s. co m alarmManger.set(type, triggerAtMillis, operation); } } }