private void setImpl( int type, long triggerAtMillis, long windowMillis, long intervalMillis, PendingIntent operation, WorkSource workSource) { if (triggerAtMillis < 0) { /* NOTYET if (mAlwaysExact) { // Fatal error for KLP+ apps to use negative trigger times throw new IllegalArgumentException("Invalid alarm trigger time " + triggerAtMillis); } */ triggerAtMillis = 0; } try { mService.set(type, triggerAtMillis, windowMillis, intervalMillis, operation, workSource); } catch (RemoteException ex) { } }
/** * Set the system default time zone. Requires the permission android.permission.SET_TIME_ZONE. * * @param timeZone in the format understood by {@link java.util.TimeZone} */ public void setTimeZone(String timeZone) { try { mService.setTimeZone(timeZone); } catch (RemoteException ex) { } }
/** * Set the system wall clock time. Requires the permission android.permission.SET_TIME. * * @param millis time in milliseconds since the Epoch */ public void setTime(long millis) { try { mService.setTime(millis); } catch (RemoteException ex) { } }
/** * Remove any alarms with a matching {@link Intent}. Any alarm, of any type, whose Intent matches * this one (as defined by {@link Intent#filterEquals}), will be canceled. * * @param operation IntentSender which matches a previously added IntentSender. * @see #set */ public void cancel(PendingIntent operation) { try { mService.remove(operation); } catch (RemoteException ex) { } }