]> git.sur5r.net Git - bacula/bacula/blob - bacula/src/stored/bsr.h
be8ef84d379dfa79851415b062f8ab3f433ab1cf
[bacula/bacula] / bacula / src / stored / bsr.h
1 /*
2  * BootStrap record definition -- for restoring files.
3  *
4  *    Kern Sibbald, June 2002
5  *
6  *   Version $Id$
7  *
8  */
9 /*
10    Copyright (C) 2000, 2001, 2002 Kern Sibbald and John Walker
11
12    This program is free software; you can redistribute it and/or
13    modify it under the terms of the GNU General Public License as
14    published by the Free Software Foundation; either version 2 of
15    the License, or (at your option) any later version.
16
17    This program is distributed in the hope that it will be useful,
18    but WITHOUT ANY WARRANTY; without even the implied warranty of
19    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20    General Public License for more details.
21
22    You should have received a copy of the GNU General Public
23    License along with this program; if not, write to the Free
24    Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
25    MA 02111-1307, USA.
26
27  */
28
29
30 #ifndef __BSR_H
31 #define __BSR_H 1
32
33 #include "findlib/find.h"
34
35 /*
36  * !!!!!!!!!!!!!!!!!! NOTE !!!!!!!!!!!!!!!!!!!!!!!!!!!!!
37  * !!!                                               !!!
38  * !!!   All records must have a pointer to          !!!
39  * !!!   the next item as the first item defined.    !!!
40  * !!!                                               !!!
41  * !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
42  */
43
44 typedef struct s_bsr_client {
45    struct s_bsr_client *next;
46    char *ClientName;
47 } BSR_CLIENT;
48
49 typedef struct s_bsr_sessid {
50    struct s_bsr_sessid *next;
51    uint32_t sessid;
52    uint32_t sessid2;
53    int found;
54 } BSR_SESSID;
55
56 typedef struct s_bsr_sesstime {
57    struct s_bsr_sesstime *next;
58    uint32_t sesstime;
59    int found;
60 } BSR_SESSTIME;
61
62 typedef struct s_bsr_volfile {
63    struct s_bsr_volfile *next;
64    uint32_t sfile;                    /* start file */
65    uint32_t efile;                    /* end file */
66    int found;
67 } BSR_VOLFILE;
68
69 typedef struct s_bsr_findex {
70    struct s_bsr_findex *next;
71    int32_t findex;                    /* start file index */
72    int32_t findex2;                   /* end file index */
73    int found;
74 } BSR_FINDEX;
75
76 typedef struct s_bsr_jobid {
77    struct s_bsr_jobid *next;
78    uint32_t JobId;
79    uint32_t JobId2;
80    int found;
81 } BSR_JOBID;
82
83 typedef struct s_bsr_jobtype {
84    struct s_bsr_jobtype *next;
85    uint32_t JobType;
86 } BSR_JOBTYPE;
87
88 typedef struct s_bsr_joblevel {
89    struct s_bsr_joblevel *next;
90    uint32_t JobLevel;
91 } BSR_JOBLEVEL;
92
93 typedef struct s_bsr_job {
94    struct s_bsr_job *next;
95    char *Job;
96    int found;
97 } BSR_JOB;
98
99
100 typedef struct s_bsr {
101    struct s_bsr *next;                /* pointer to next one */
102    int           done;                /* set when everything found */
103    char         *VolumeName;
104    BSR_VOLFILE  *volfile;
105    BSR_SESSTIME *sesstime;
106    BSR_SESSID   *sessid;
107    BSR_JOBID    *JobId;
108    BSR_JOB      *job;
109    BSR_CLIENT   *client;
110    BSR_FINDEX   *FileIndex;
111    BSR_JOBTYPE  *JobType;
112    BSR_JOBLEVEL *JobLevel;
113    FF_PKT *ff;                        /* include/exclude */
114 } BSR;
115
116
117 #endif