core: shrink blockchainer.StateRoot further, leave simple RO methods

This commit is contained in:
Roman Khimov 2022-01-14 02:09:16 +03:00
parent 077d5ccb03
commit ddb23ccf78
4 changed files with 27 additions and 32 deletions

View file

@ -3,13 +3,11 @@ package blockchainer
import (
"github.com/nspcc-dev/neo-go/pkg/core/state"
"github.com/nspcc-dev/neo-go/pkg/core/storage"
"github.com/nspcc-dev/neo-go/pkg/crypto/keys"
"github.com/nspcc-dev/neo-go/pkg/util"
)
// StateRoot represents local state root module.
type StateRoot interface {
AddStateRoot(root *state.MPTRoot) error
CurrentLocalHeight() uint32
CurrentLocalStateRoot() util.Uint256
CurrentValidatedHeight() uint32
@ -17,6 +15,4 @@ type StateRoot interface {
GetState(root util.Uint256, key []byte) ([]byte, error)
GetStateProof(root util.Uint256, key []byte) ([][]byte, error)
GetStateRoot(height uint32) (*state.MPTRoot, error)
GetStateValidators(height uint32) keys.PublicKeys
SetUpdateValidatorsCallback(func(uint32, keys.PublicKeys))
}