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

Kai Reinhard
19.04.2021 341d1baaf08d82b5af1509441050c0eef234ea5f
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.BorgVersion
 
/**
 * 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 borgVersion: BorgVersion? = null
        private set
 
    fun setQueueStatistics(queueStatistics: BorgQueueStatistics?): SystemInfo {
        this.queueStatistics = queueStatistics
        return this
    }
 
    fun setConfigurationOK(configurationOK: Boolean): SystemInfo {
        this.configurationOK = configurationOK
        return this
    }
 
    fun setBorgVersion(borgVersion: BorgVersion?): SystemInfo {
        this.borgVersion = borgVersion
        return this
    }
}