OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CC_TEST_SIMPLE_TASK_RUNNER_H_ | |
6 #define CC_TEST_SIMPLE_TASK_RUNNER_H_ | |
7 | |
8 #include "cc/raster/tile_task.h" | |
9 | |
10 namespace cc { | |
11 | |
12 // This task runner operates on single task. User has to call respective | |
13 // functions to operate on task. | |
14 class SimpleTaskRunner { | |
vmpstr
2016/05/20 23:23:19
nit: can you rename this to something to indicate
| |
15 public: | |
16 // Schedules, runs and completes the task. | |
17 static void ProcessTask(TileTask* task); | |
18 static void ScheduleTask(TileTask* task); | |
19 static void CancelTask(TileTask* task); | |
20 // Before running the task it must be scheduled. Call ScheduleTask() before | |
21 // calling this function. This starts, runs and finishes the task. | |
22 static void RunTask(TileTask* task); | |
23 // Before completing the task it must be canceled or finished by running. Call | |
24 // RunTask() or CancelTask before calling this function. | |
25 static void CompleteTask(TileTask* task); | |
26 }; | |
27 | |
28 } // namespace cc | |
29 | |
30 #endif // CC_TEST_SIMPLE_TASK_RUNNER_H_ | |
OLD | NEW |