mirror of https://github.com/micromata/borgbackup-butler.git

Kai Reinhard
19.29.2022 9926a79503c9bd6454c076f2b60cd577f6061e4d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
package de.micromata.borgbutler.server.rest
 
import de.micromata.borgbutler.BorgQueueStatistics
import de.micromata.borgbutler.server.BorgConfig
 
/**
 * Statistics of all the job queues, especially the number of total queued and running jobs.
 * This is used e. g. by the client for showing a badge near to the menu entry "job monitor" with the number
 * of Jobs in the queues.
 */
class SystemInfo {
    var queueStatistics: BorgQueueStatistics? = null
        private set
    var configurationOK = false
        private set
    var borgConfig: BorgConfig? = null
        private set
 
    fun setQueueStatistics(queueStatistics: BorgQueueStatistics?): SystemInfo {
        this.queueStatistics = queueStatistics
        return this
    }
 
    fun setConfigurationOK(configurationOK: Boolean): SystemInfo {
        this.configurationOK = configurationOK
        return this
    }
 
    fun setBorgConfig(borgConfig: BorgConfig?): SystemInfo {
        this.borgConfig = borgConfig
        return this
    }
}