Ejemplo n.º 1
0
// NewResourcePersistence is a function that may be passed to
// state.SetResourcesPersistence(). It will be used in the core state
// package to produce the resource persistence.
func NewResourcePersistence(persist corestate.Persistence) corestate.ResourcesPersistence {
	return corestate.NewResourcePersistence(persist)
}
Ejemplo n.º 2
0
// Persistence implements resource/state.RawState.
func (st rawState) Persistence() state.Persistence {
	persist := corestate.NewResourcePersistence(st.persist)
	return resourcePersistence{persist}
}