// automatically generated by stateify.

package fsbridge

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

func (x *fsFile) StateTypeName() string {
	return "pkg/sentry/fsbridge.fsFile"
}

func (x *fsFile) StateFields() []string {
	return []string{
		"file",
	}
}

func (x *fsFile) beforeSave() {}

func (x *fsFile) StateSave(m state.Sink) {
	x.beforeSave()
	m.Save(0, &x.file)
}

func (x *fsFile) afterLoad() {}

func (x *fsFile) StateLoad(m state.Source) {
	m.Load(0, &x.file)
}

func (x *fsLookup) StateTypeName() string {
	return "pkg/sentry/fsbridge.fsLookup"
}

func (x *fsLookup) StateFields() []string {
	return []string{
		"mntns",
		"root",
		"workingDir",
	}
}

func (x *fsLookup) beforeSave() {}

func (x *fsLookup) StateSave(m state.Sink) {
	x.beforeSave()
	m.Save(0, &x.mntns)
	m.Save(1, &x.root)
	m.Save(2, &x.workingDir)
}

func (x *fsLookup) afterLoad() {}

func (x *fsLookup) StateLoad(m state.Source) {
	m.Load(0, &x.mntns)
	m.Load(1, &x.root)
	m.Load(2, &x.workingDir)
}

func (x *VFSFile) StateTypeName() string {
	return "pkg/sentry/fsbridge.VFSFile"
}

func (x *VFSFile) StateFields() []string {
	return []string{
		"file",
	}
}

func (x *VFSFile) beforeSave() {}

func (x *VFSFile) StateSave(m state.Sink) {
	x.beforeSave()
	m.Save(0, &x.file)
}

func (x *VFSFile) afterLoad() {}

func (x *VFSFile) StateLoad(m state.Source) {
	m.Load(0, &x.file)
}

func (x *vfsLookup) StateTypeName() string {
	return "pkg/sentry/fsbridge.vfsLookup"
}

func (x *vfsLookup) StateFields() []string {
	return []string{
		"mntns",
		"root",
		"workingDir",
	}
}

func (x *vfsLookup) beforeSave() {}

func (x *vfsLookup) StateSave(m state.Sink) {
	x.beforeSave()
	m.Save(0, &x.mntns)
	m.Save(1, &x.root)
	m.Save(2, &x.workingDir)
}

func (x *vfsLookup) afterLoad() {}

func (x *vfsLookup) StateLoad(m state.Source) {
	m.Load(0, &x.mntns)
	m.Load(1, &x.root)
	m.Load(2, &x.workingDir)
}

func init() {
	state.Register((*fsFile)(nil))
	state.Register((*fsLookup)(nil))
	state.Register((*VFSFile)(nil))
	state.Register((*vfsLookup)(nil))
}