executor

package
v0.0.0-...-3606b63 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 13, 2019 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GeHashReciverKV

func GeHashReciverKV(hashlockID []byte, information *pty.Hashlockquery) *types.KeyValue

GeHashReciverKV gen KV

func GetHashReciver

func GetHashReciver(db dbm.KVDB, hashlockID []byte) (*pty.Hashlockquery, error)

GetHashReciver get hashlock

func GetName

func GetName() string

GetName for hashlock

func Init

func Init(name string, sub []byte)

Init hashlock

func Key

func Key(id []byte) (key []byte)

Key for hashlock

func NewHashlockquery

func NewHashlockquery() *pty.Hashlockquery

NewHashlockquery gen query instance

func SetHashReciver

func SetHashReciver(db dbm.KVDB, hashlockID []byte, information *pty.Hashlockquery) error

SetHashReciver save hashlock

func UpdateHashReciver

func UpdateHashReciver(cachedb dbm.KVDB, hashlockID []byte, information pty.Hashlockquery) (*types.KeyValue, error)

UpdateHashReciver update status for hashlock

Types

type Action

type Action struct {
	// contains filtered or unexported fields
}

Action def

func NewAction

func NewAction(h *Hashlock, tx *types.Transaction, execaddr string) *Action

NewAction gen action instance

func (*Action) Hashlocklock

func (action *Action) Hashlocklock(hlock *pty.HashlockLock) (*types.Receipt, error)

Hashlocklock Action

func (*Action) Hashlocksend

func (action *Action) Hashlocksend(send *pty.HashlockSend) (*types.Receipt, error)

Hashlocksend Action

func (*Action) Hashlockunlock

func (action *Action) Hashlockunlock(unlock *pty.HashlockUnlock) (*types.Receipt, error)

Hashlockunlock Action

type DB

type DB struct {
	pty.Hashlock
}

DB struct

func NewDB

func NewDB(id []byte, returnWallet string, toAddress string, blocktime int64, amount int64, time int64) *DB

NewDB instance

func (*DB) GetKVSet

func (h *DB) GetKVSet() (kvset []*types.KeyValue)

GetKVSet for hashlock

func (*DB) Save

func (h *DB) Save(db dbm.KV)

Save KV

type Hashlock

type Hashlock struct {
	drivers.DriverBase
}

Hashlock driver

func (*Hashlock) CheckReceiptExecOk

func (h *Hashlock) CheckReceiptExecOk() bool

CheckReceiptExecOk return true to check if receipt ty is ok

func (*Hashlock) CheckTx

func (h *Hashlock) CheckTx(tx *types.Transaction, index int) error

CheckTx nil

func (*Hashlock) ExecDelLocal_Hlock

func (h *Hashlock) ExecDelLocal_Hlock(hlock *pty.HashlockLock, tx *types.Transaction, receipt *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecDelLocal_Hlock Action

func (*Hashlock) ExecDelLocal_Hsend

func (h *Hashlock) ExecDelLocal_Hsend(hsend *pty.HashlockSend, tx *types.Transaction, receipt *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecDelLocal_Hsend Action

func (*Hashlock) ExecDelLocal_Hunlock

func (h *Hashlock) ExecDelLocal_Hunlock(hunlock *pty.HashlockUnlock, tx *types.Transaction, receipt *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecDelLocal_Hunlock Action

func (*Hashlock) ExecLocal_Hlock

func (h *Hashlock) ExecLocal_Hlock(hlock *pty.HashlockLock, tx *types.Transaction, receipt *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_Hlock Action

func (*Hashlock) ExecLocal_Hsend

func (h *Hashlock) ExecLocal_Hsend(hsend *pty.HashlockSend, tx *types.Transaction, receipt *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_Hsend Action

func (*Hashlock) ExecLocal_Hunlock

func (h *Hashlock) ExecLocal_Hunlock(hunlock *pty.HashlockUnlock, tx *types.Transaction, receipt *types.ReceiptData, index int) (*types.LocalDBSet, error)

ExecLocal_Hunlock Action

func (*Hashlock) Exec_Hlock

func (h *Hashlock) Exec_Hlock(hlock *pty.HashlockLock, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_Hlock Action

func (*Hashlock) Exec_Hsend

func (h *Hashlock) Exec_Hsend(transfer *pty.HashlockSend, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_Hsend Action

func (*Hashlock) Exec_Hunlock

func (h *Hashlock) Exec_Hunlock(transfer *pty.HashlockUnlock, tx *types.Transaction, index int) (*types.Receipt, error)

Exec_Hunlock Action

func (*Hashlock) GetDriverName

func (h *Hashlock) GetDriverName() string

GetDriverName driverName

func (*Hashlock) GetTxsByHashlockID

func (n *Hashlock) GetTxsByHashlockID(hashlockID []byte, differTime int64) (types.Message, error)

GetTxsByHashlockID get hashlock record

func (*Hashlock) Query_GetHashlocKById

func (h *Hashlock) Query_GetHashlocKById(in []byte) (types.Message, error)

Query_GetHashlocKById get hashlock instance

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL