Loading api/current.txt +1 −1 Original line number Diff line number Diff line Loading @@ -5245,7 +5245,7 @@ package android.app.task { public abstract class TaskService extends android.app.Service { ctor public TaskService(); method public final android.os.IBinder onBind(android.content.Intent); method public abstract void onStartTask(android.app.task.TaskParams); method public abstract boolean onStartTask(android.app.task.TaskParams); method public abstract boolean onStopTask(android.app.task.TaskParams); method public final void taskFinished(android.app.task.TaskParams, boolean); field public static final java.lang.String PERMISSION_BIND = "android.permission.BIND_TASK_SERVICE"; services/core/java/com/android/server/task/StateChangedListener.java +3 −3 Original line number Diff line number Diff line Loading @@ -19,9 +19,9 @@ package com.android.server.task; import com.android.server.task.controllers.TaskStatus; /** * Interface through which a {@link StateController} informs the * {@link com.android.server.task.TaskManagerService} that there are some tasks potentially ready * to be run. * Interface through which a {@link com.android.server.task.controllers.StateController} informs * the {@link com.android.server.task.TaskManagerService} that there are some tasks potentially * ready to be run. */ public interface StateChangedListener { /** Loading services/core/java/com/android/server/task/TaskManagerService.java +1 −2 Original line number Diff line number Diff line Loading @@ -136,7 +136,6 @@ public class TaskManagerService extends com.android.server.SystemService * For now this takes the task and if it's ready to run it will run it. In future we might not * provide the task, so that the StateChangedListener has to run through its list of tasks to * see which are ready. This will further decouple the controllers from the execution logic. * @param taskStatus The state of the task which has changed. */ @Override public void onTaskStateChanged(TaskStatus taskStatus) { Loading Loading @@ -170,7 +169,7 @@ public class TaskManagerService extends com.android.server.SystemService } @Override public void onClientExecutionCompleted(int serviceToken) { public void onAllTasksCompleted(int serviceToken) { } Loading services/core/java/com/android/server/task/TaskServiceContext.java +2 −2 Original line number Diff line number Diff line Loading @@ -230,7 +230,7 @@ public class TaskServiceContext extends ITaskCallback.Stub implements ServiceCon * tasks, then we do the shutdown. */ private void startShutdown() { mCompletedListener.onClientExecutionCompleted(token); mCompletedListener.onAllTasksCompleted(token); mCallbackHandler.obtainMessage(MSG_SHUTDOWN).sendToTarget(); } Loading Loading @@ -389,7 +389,7 @@ public class TaskServiceContext extends ITaskCallback.Stub implements ServiceCon * This TaskServiceContext is shutting down. Remove all the tasks from the pending queue * and reschedule them as if they had failed. * Before posting this message, caller must invoke * {@link com.android.server.task.TaskCompletedListener#onClientExecutionCompleted(int)} * {@link com.android.server.task.TaskCompletedListener#onAllTasksCompleted(int)}. */ private void handleShutdownH() { for (int i = 0; i < mPending.size(); i++) { Loading services/core/java/com/android/server/task/controllers/ConnectivityController.java +3 −3 Original line number Diff line number Diff line Loading @@ -56,7 +56,7 @@ public class ConnectivityController extends StateController { } @Override public void maybeStartTrackingTask(TaskStatus taskStatus) { public void maybeTrackTaskState(TaskStatus taskStatus) { if (taskStatus.hasConnectivityConstraint() || taskStatus.hasMeteredConstraint()) { taskStatus.connectivityConstraintSatisfied.set(mConnectivity); taskStatus.meteredConstraintSatisfied.set(mMetered); Loading @@ -65,7 +65,7 @@ public class ConnectivityController extends StateController { } @Override public void maybeStopTrackingTask(TaskStatus taskStatus) { public void removeTaskStateIfTracked(TaskStatus taskStatus) { mTrackedTasks.remove(taskStatus); } Loading Loading @@ -111,7 +111,7 @@ public class ConnectivityController extends StateController { mMetered = false; mConnectivity = !intent.getBooleanExtra(ConnectivityManager.EXTRA_NO_CONNECTIVITY, false); if (isConnected) { // No point making the call if we know there's no conn. if (mConnectivity) { // No point making the call if we know there's no conn. mMetered = connManager.isActiveNetworkMetered(); } updateTrackedTasks(userid); Loading Loading
api/current.txt +1 −1 Original line number Diff line number Diff line Loading @@ -5245,7 +5245,7 @@ package android.app.task { public abstract class TaskService extends android.app.Service { ctor public TaskService(); method public final android.os.IBinder onBind(android.content.Intent); method public abstract void onStartTask(android.app.task.TaskParams); method public abstract boolean onStartTask(android.app.task.TaskParams); method public abstract boolean onStopTask(android.app.task.TaskParams); method public final void taskFinished(android.app.task.TaskParams, boolean); field public static final java.lang.String PERMISSION_BIND = "android.permission.BIND_TASK_SERVICE";
services/core/java/com/android/server/task/StateChangedListener.java +3 −3 Original line number Diff line number Diff line Loading @@ -19,9 +19,9 @@ package com.android.server.task; import com.android.server.task.controllers.TaskStatus; /** * Interface through which a {@link StateController} informs the * {@link com.android.server.task.TaskManagerService} that there are some tasks potentially ready * to be run. * Interface through which a {@link com.android.server.task.controllers.StateController} informs * the {@link com.android.server.task.TaskManagerService} that there are some tasks potentially * ready to be run. */ public interface StateChangedListener { /** Loading
services/core/java/com/android/server/task/TaskManagerService.java +1 −2 Original line number Diff line number Diff line Loading @@ -136,7 +136,6 @@ public class TaskManagerService extends com.android.server.SystemService * For now this takes the task and if it's ready to run it will run it. In future we might not * provide the task, so that the StateChangedListener has to run through its list of tasks to * see which are ready. This will further decouple the controllers from the execution logic. * @param taskStatus The state of the task which has changed. */ @Override public void onTaskStateChanged(TaskStatus taskStatus) { Loading Loading @@ -170,7 +169,7 @@ public class TaskManagerService extends com.android.server.SystemService } @Override public void onClientExecutionCompleted(int serviceToken) { public void onAllTasksCompleted(int serviceToken) { } Loading
services/core/java/com/android/server/task/TaskServiceContext.java +2 −2 Original line number Diff line number Diff line Loading @@ -230,7 +230,7 @@ public class TaskServiceContext extends ITaskCallback.Stub implements ServiceCon * tasks, then we do the shutdown. */ private void startShutdown() { mCompletedListener.onClientExecutionCompleted(token); mCompletedListener.onAllTasksCompleted(token); mCallbackHandler.obtainMessage(MSG_SHUTDOWN).sendToTarget(); } Loading Loading @@ -389,7 +389,7 @@ public class TaskServiceContext extends ITaskCallback.Stub implements ServiceCon * This TaskServiceContext is shutting down. Remove all the tasks from the pending queue * and reschedule them as if they had failed. * Before posting this message, caller must invoke * {@link com.android.server.task.TaskCompletedListener#onClientExecutionCompleted(int)} * {@link com.android.server.task.TaskCompletedListener#onAllTasksCompleted(int)}. */ private void handleShutdownH() { for (int i = 0; i < mPending.size(); i++) { Loading
services/core/java/com/android/server/task/controllers/ConnectivityController.java +3 −3 Original line number Diff line number Diff line Loading @@ -56,7 +56,7 @@ public class ConnectivityController extends StateController { } @Override public void maybeStartTrackingTask(TaskStatus taskStatus) { public void maybeTrackTaskState(TaskStatus taskStatus) { if (taskStatus.hasConnectivityConstraint() || taskStatus.hasMeteredConstraint()) { taskStatus.connectivityConstraintSatisfied.set(mConnectivity); taskStatus.meteredConstraintSatisfied.set(mMetered); Loading @@ -65,7 +65,7 @@ public class ConnectivityController extends StateController { } @Override public void maybeStopTrackingTask(TaskStatus taskStatus) { public void removeTaskStateIfTracked(TaskStatus taskStatus) { mTrackedTasks.remove(taskStatus); } Loading Loading @@ -111,7 +111,7 @@ public class ConnectivityController extends StateController { mMetered = false; mConnectivity = !intent.getBooleanExtra(ConnectivityManager.EXTRA_NO_CONNECTIVITY, false); if (isConnected) { // No point making the call if we know there's no conn. if (mConnectivity) { // No point making the call if we know there's no conn. mMetered = connManager.isActiveNetworkMetered(); } updateTrackedTasks(userid); Loading