2 Bacula(R) - The Network Backup Solution
4 Copyright (C) 2000-2017 Kern Sibbald
6 The original author of Bacula is Kern Sibbald, with contributions
7 from many others, a complete list can be found in the file AUTHORS.
9 You may use this file and others of this release according to the
10 license defined in the LICENSE file, which includes the Affero General
11 Public License, v3.0 ("AGPLv3") and some additional permissions and
12 terms pursuant to its AGPLv3 Section 7.
14 This notice must be preserved when any source code is
15 conveyed and/or propagated.
17 Bacula(R) is a registered trademark of Kern Sibbald.
24 #include <QtCore/QObject>
25 #include "tray_conf.h"
41 /* The task should emit a signal when done */
42 class task: public QObject
53 char *arg; /* Argument that can be used by some tasks */
60 } result; /* The task might return something */
62 task(): QObject(), res(NULL), type(TASK_NONE), status(false), curline(NULL),
63 curend(NULL), arg(NULL), arg2(NULL)
65 errmsg = get_pool_memory(PM_FNAME);
67 memset(result.c, 0, sizeof(result.c));
71 disconnect(); /* disconnect all signals */
72 free_pool_memory(errmsg);
79 void init(RESMON *s, int t) {
87 bool connect_bacula();
89 bool read_status_terminated(RESMON *res);
90 bool read_status_header(RESMON *res);
91 bool read_status_running(RESMON *res);
93 bool disconnect_bacula();
98 void mark_as_failed() {
102 bool get_resources();
103 bool get_next_line(RESMON *res);
104 bool get_job_defaults(); /* Look r->defaults.job */
106 bool get_job_info(const char *level); /* look r->info */
112 worker *worker_start();
113 void worker_stop(worker *);