summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/fsbridge/fsbridge_state_autogen.go
blob: d370b2d47ad8da2a4a48b912b581df39193bec12 (plain)
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
// automatically generated by stateify.

package fsbridge

import (
	"gvisor.dev/gvisor/pkg/state"
)

func (x *fsFile) beforeSave() {}
func (x *fsFile) save(m state.Map) {
	x.beforeSave()
	m.Save("file", &x.file)
}

func (x *fsFile) afterLoad() {}
func (x *fsFile) load(m state.Map) {
	m.Load("file", &x.file)
}

func (x *fsLookup) beforeSave() {}
func (x *fsLookup) save(m state.Map) {
	x.beforeSave()
	m.Save("mntns", &x.mntns)
	m.Save("root", &x.root)
	m.Save("workingDir", &x.workingDir)
}

func (x *fsLookup) afterLoad() {}
func (x *fsLookup) load(m state.Map) {
	m.Load("mntns", &x.mntns)
	m.Load("root", &x.root)
	m.Load("workingDir", &x.workingDir)
}

func (x *VFSFile) beforeSave() {}
func (x *VFSFile) save(m state.Map) {
	x.beforeSave()
	m.Save("file", &x.file)
}

func (x *VFSFile) afterLoad() {}
func (x *VFSFile) load(m state.Map) {
	m.Load("file", &x.file)
}

func (x *vfsLookup) beforeSave() {}
func (x *vfsLookup) save(m state.Map) {
	x.beforeSave()
	m.Save("mntns", &x.mntns)
	m.Save("root", &x.root)
	m.Save("workingDir", &x.workingDir)
}

func (x *vfsLookup) afterLoad() {}
func (x *vfsLookup) load(m state.Map) {
	m.Load("mntns", &x.mntns)
	m.Load("root", &x.root)
	m.Load("workingDir", &x.workingDir)
}

func init() {
	state.Register("pkg/sentry/fsbridge.fsFile", (*fsFile)(nil), state.Fns{Save: (*fsFile).save, Load: (*fsFile).load})
	state.Register("pkg/sentry/fsbridge.fsLookup", (*fsLookup)(nil), state.Fns{Save: (*fsLookup).save, Load: (*fsLookup).load})
	state.Register("pkg/sentry/fsbridge.VFSFile", (*VFSFile)(nil), state.Fns{Save: (*VFSFile).save, Load: (*VFSFile).load})
	state.Register("pkg/sentry/fsbridge.vfsLookup", (*vfsLookup)(nil), state.Fns{Save: (*vfsLookup).save, Load: (*vfsLookup).load})
}