Debian Codegraph @

include/jobs/jobmanager.h

raw symbols SCIP
1 /* fre:ac - free audio converter
2 * Copyright (C) 2001-2019 Robert Kausch <[email protected]>
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License as
6 * published by the Free Software Foundation, either version 2 of
7 * the License, or (at your option) any later version.
8 *
9 * THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
10 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
11 * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. */
12
13 #ifndef H_FREAC_JOBMANAGER
14 #define H_FREAC_JOBMANAGER
15
16 #include "job.h"
17
18 using namespace smooth;
19
20 namespace freac
21 {
22 class JobManager
23 {
24 private:
25 /* Singleton class, therefore private constructor/destructor
26 */
27 static JobManager *instance;
28
29 JobManager();
30 virtual ~JobManager();
31
32 Bool exitThread;
33 Threads::Thread *managerThread;
34
35 Array<Job *> finished;
36 public:
37 /* Methods to start and quit the JobManager
38 */
39 static Error Start();
40 static Error Quit();
41 slots:
42 Void ManagerThread();
43
44 Void OnFinishJob(Job *);
45 };
46 };
47
48 #endif