github.com/MerlinKodo/gvisor@v0.0.0-20231110090155-957f62ecf90e/runsc/boot/boot_state_autogen.go (about) 1 // automatically generated by stateify. 2 3 package boot 4 5 import ( 6 "github.com/MerlinKodo/gvisor/pkg/state" 7 ) 8 9 func (f *sandboxNetstackCreator) StateTypeName() string { 10 return "runsc/boot.sandboxNetstackCreator" 11 } 12 13 func (f *sandboxNetstackCreator) StateFields() []string { 14 return []string{ 15 "clock", 16 "uniqueID", 17 "allowPacketEndpointWrite", 18 } 19 } 20 21 func (f *sandboxNetstackCreator) beforeSave() {} 22 23 // +checklocksignore 24 func (f *sandboxNetstackCreator) StateSave(stateSinkObject state.Sink) { 25 f.beforeSave() 26 stateSinkObject.Save(0, &f.clock) 27 stateSinkObject.Save(1, &f.uniqueID) 28 stateSinkObject.Save(2, &f.allowPacketEndpointWrite) 29 } 30 31 func (f *sandboxNetstackCreator) afterLoad() {} 32 33 // +checklocksignore 34 func (f *sandboxNetstackCreator) StateLoad(stateSourceObject state.Source) { 35 stateSourceObject.Load(0, &f.clock) 36 stateSourceObject.Load(1, &f.uniqueID) 37 stateSourceObject.Load(2, &f.allowPacketEndpointWrite) 38 } 39 40 func init() { 41 state.Register((*sandboxNetstackCreator)(nil)) 42 }