Repository navigation
Expand file tree
/
Copy pathBackupInfo.java
More file actions
76 lines (68 loc) · 1.68 KB
/
Copy pathBackupInfo.java
File metadata and controls
76 lines (68 loc) · 1.68 KB
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
// Copyright (c) 2011-present, Facebook, Inc. All rights reserved.
// This source code is licensed under both the GPLv2 (found in the
// COPYING file in the root directory) and Apache 2.0 License
// (found in the LICENSE.Apache file in the root directory).
package org.rocksdb;
/**
* Instances of this class describe a Backup made by
* {@link org.rocksdb.BackupEngine}.
*/
public class BackupInfo {
/**
* Package private constructor used to create instances
* of BackupInfo by {@link org.rocksdb.BackupEngine}
*
* @param backupId id of backup
* @param timestamp timestamp of backup
* @param size size of backup
* @param numberFiles number of files related to this backup.
*/
BackupInfo(final int backupId, final long timestamp, final long size, final int numberFiles,
final String app_metadata) {
backupId_ = backupId;
timestamp_ = timestamp;
size_ = size;
numberFiles_ = numberFiles;
app_metadata_ = app_metadata;
}
/**
*
* @return the backup id.
*/
public int backupId() {
return backupId_;
}
/**
*
* @return the timestamp of the backup.
*/
public long timestamp() {
return timestamp_;
}
/**
*
* @return the size of the backup
*/
public long size() {
return size_;
}
/**
*
* @return the number of files of this backup.
*/
public int numberFiles() {
return numberFiles_;
}
/**
*
* @return the associated application metadata, or null
*/
public String appMetadata() {
return app_metadata_;
}
private final int backupId_;
private final long timestamp_;
private final long size_;
private final int numberFiles_;
private final String app_metadata_;
}