Home | History | Annotate | Download | only in action

Lines Matching defs:action

17 package com.android.messaging.datamodel.action;
47 * Start action by sending intent to the service
48 * @param action - action to start
50 protected static void startAction(final Action action) {
53 actionBundle.putParcelable(BUNDLE_ACTION, action);
55 action.markStart();
60 * Schedule an action to run after specified delay using alarm manager to send pendingintent
61 * @param action - action to start
63 * @param delayMs - delay in ms (from now) before action will start
65 protected static void scheduleAction(final Action action, final int requestCode,
69 actionBundle.putParcelable(BUNDLE_ACTION, action);
80 protected static void handleResponseFromBackgroundWorker(final Action action,
85 actionBundle.putParcelable(BUNDLE_ACTION, action);
96 protected static void handleFailureFromBackgroundWorker(final Action action,
101 actionBundle.putParcelable(BUNDLE_ACTION, action);
146 static final String ACTION = "com.android.messaging.datamodel.PENDING_ACTION";
149 * Allocate an intent with a specific opcode and alarm action.
154 intent.setAction(ACTION);
186 * Creates a pending intent that will trigger a data model action when the intent is
190 final Action action, final int requestCode, final boolean launchesAnActivity) {
193 actionBundle.putParcelable(BUNDLE_ACTION, action);
238 // Perhaps we should keep large structures in the action monitor?
261 Action action;
266 action = (Action) actionBundle.getParcelable(BUNDLE_ACTION);
267 executeAction(action);
272 action = (Action) actionBundle.getParcelable(BUNDLE_ACTION);
274 processBackgroundResponse(action, response);
279 action = (Action) actionBundle.getParcelable(BUNDLE_ACTION);
280 processBackgroundFailure(action);
288 action.sendBackgroundActions(mBackgroundWorker);
297 * Local execution of action on ActionService thread
299 private void executeAction(final Action action) {
300 action.markBeginExecute();
302 final LoggingTimer timer = createLoggingTimer(action, "#executeAction");
305 final Object result = action.executeAction();
309 action.markEndExecute(result);
315 private void processBackgroundResponse(final Action action, final Bundle response) {
316 final LoggingTimer timer = createLoggingTimer(action, "#processBackgroundResponse");
319 action.processBackgroundWorkResponse(response);
327 private void processBackgroundFailure(final Action action) {
328 final LoggingTimer timer = createLoggingTimer(action, "#processBackgroundFailure");
331 action.processBackgroundWorkFailure();
337 final Action action, final String methodName) {
338 return new LoggingTimer(TAG, action.getClass().getSimpleName() + methodName,