Documentation ¶
Index ¶
- Constants
- Variables
- type IState
- type KvStash
- type NameString
- type NoStateDB
- func (n *NoStateDB) Commit() ([]byte, error)
- func (n *NoStateDB) Delete(triName NameString, key []byte)
- func (n *NoStateDB) Discard()
- func (n *NoStateDB) DiscardAll()
- func (n *NoStateDB) Exist(triName NameString, key []byte) bool
- func (n *NoStateDB) FinalizeBlock(block *types.Block)
- func (n *NoStateDB) Get(triName NameString, key []byte) ([]byte, error)
- func (n *NoStateDB) GetByBlockHash(triName NameString, key []byte, block *types.Block) ([]byte, error)
- func (n *NoStateDB) GetFinalized(triName NameString, key []byte) ([]byte, error)
- func (n *NoStateDB) NextTxn()
- func (n *NoStateDB) Set(triName NameString, key, value []byte)
- func (n *NoStateDB) StartBlock(block *types.Block)
- type Ops
- type SpmtKV
- func (skv *SpmtKV) Commit() ([]byte, error)
- func (skv *SpmtKV) Delete(triName NameString, key []byte)
- func (skv *SpmtKV) Discard()
- func (skv *SpmtKV) DiscardAll()
- func (skv *SpmtKV) Exist(triName NameString, key []byte) bool
- func (skv *SpmtKV) FinalizeBlock(block *types.Block)
- func (skv *SpmtKV) Get(triName NameString, key []byte) ([]byte, error)
- func (skv *SpmtKV) GetByBlockHash(triName NameString, key []byte, block *types.Block) ([]byte, error)
- func (skv *SpmtKV) GetFinalized(triName NameString, key []byte) ([]byte, error)
- func (skv *SpmtKV) NextTxn()
- func (skv *SpmtKV) Set(triName NameString, key, value []byte)
- func (skv *SpmtKV) StartBlock(block *types.Block)
- type TxnStashes
Constants ¶
View Source
const ( SpmtIndex = "spmt-index" Nodes = "spmt-nodes" Values = "spmt-values" )
View Source
const ( SetOp = iota DeleteOp )
Variables ¶
View Source
var (
EmptyRoot = HexToHash("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421")
)
Functions ¶
This section is empty.
Types ¶
type IState ¶
type IState interface { Set(triName NameString, key, value []byte) Delete(triName NameString, key []byte) Get(triName NameString, key []byte) ([]byte, error) GetFinalized(triName NameString, key []byte) ([]byte, error) Exist(triName NameString, key []byte) bool GetByBlockHash(triName NameString, key []byte, block *types.Block) ([]byte, error) Commit() ([]byte, error) NextTxn() Discard() DiscardAll() StartBlock(block *types.Block) FinalizeBlock(block *types.Block) }
TODO: need to add prove() and verify()
type NameString ¶
type NameString interface {
Name() string
}
type NoStateDB ¶ added in v1.0.12
type NoStateDB struct { }
func (*NoStateDB) Delete ¶ added in v1.0.12
func (n *NoStateDB) Delete(triName NameString, key []byte)
func (*NoStateDB) DiscardAll ¶ added in v1.0.12
func (n *NoStateDB) DiscardAll()
func (*NoStateDB) Exist ¶ added in v1.0.12
func (n *NoStateDB) Exist(triName NameString, key []byte) bool
func (*NoStateDB) FinalizeBlock ¶ added in v1.0.12
func (*NoStateDB) Get ¶ added in v1.0.12
func (n *NoStateDB) Get(triName NameString, key []byte) ([]byte, error)
func (*NoStateDB) GetByBlockHash ¶ added in v1.0.12
func (*NoStateDB) GetFinalized ¶ added in v1.0.12
func (n *NoStateDB) GetFinalized(triName NameString, key []byte) ([]byte, error)
func (*NoStateDB) Set ¶ added in v1.0.12
func (n *NoStateDB) Set(triName NameString, key, value []byte)
func (*NoStateDB) StartBlock ¶ added in v1.0.12
type SpmtKV ¶
type SpmtKV struct {
// contains filtered or unexported fields
}
func (*SpmtKV) Delete ¶
func (skv *SpmtKV) Delete(triName NameString, key []byte)
func (*SpmtKV) DiscardAll ¶
func (skv *SpmtKV) DiscardAll()
func (*SpmtKV) FinalizeBlock ¶
func (*SpmtKV) GetByBlockHash ¶
func (skv *SpmtKV) GetByBlockHash(triName NameString, key []byte, block *types.Block) ([]byte, error)
FIXME
func (*SpmtKV) GetFinalized ¶
func (skv *SpmtKV) GetFinalized(triName NameString, key []byte) ([]byte, error)
func (*SpmtKV) Set ¶
func (skv *SpmtKV) Set(triName NameString, key, value []byte)
func (*SpmtKV) StartBlock ¶
type TxnStashes ¶
type TxnStashes struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.