Documentation ¶
Index ¶
- type Block
- func (b *Block) Accept() error
- func (b *Block) Bytes() []byte
- func (b *Block) Height() uint64
- func (b *Block) ID() *hash.Hash
- func (b *Block) Parent() *hash.Hash
- func (b *Block) Reject() error
- func (b *Block) SetStatus(status consensus.Status)
- func (b *Block) Status() consensus.Status
- func (b *Block) String() string
- func (b *Block) Timestamp() time.Time
- func (b *Block) Transactions() []consensus.Tx
- func (b *Block) Verify() error
- type ChainState
- type Context
- type ExportTx
- type ImportTx
- func (itx *ImportTx) CheckSanity() error
- func (itx *ImportTx) GetPKAddress() (*address.SecpPubKeyAddress, error)
- func (itx *ImportTx) GetPKScript() ([]byte, error)
- func (itx *ImportTx) GetTransactionForEngine() (*types.Transaction, error)
- func (itx *ImportTx) SetCoinbaseTx(tx *types.Transaction) error
- func (itx *ImportTx) Sign(privateKey ecc.PrivateKey) error
- type Tx
- type VMI
- type VMTx
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Block ¶
func (*Block) Transactions ¶
type ChainState ¶
type ChainState struct { }
type Context ¶
type ExportTx ¶
type ExportTx struct { *Tx *types.Transaction }
func NewExportTx ¶
func NewExportTx(tx *types.Transaction) (*ExportTx, error)
func (*ExportTx) CheckSanity ¶
type ImportTx ¶
type ImportTx struct { *Tx *types.Transaction }
func NewImportTx ¶
func NewImportTx(tx *types.Transaction) (*ImportTx, error)
func (*ImportTx) CheckSanity ¶
func (*ImportTx) GetPKAddress ¶
func (itx *ImportTx) GetPKAddress() (*address.SecpPubKeyAddress, error)
func (*ImportTx) GetPKScript ¶
func (*ImportTx) GetTransactionForEngine ¶
func (itx *ImportTx) GetTransactionForEngine() (*types.Transaction, error)
func (*ImportTx) SetCoinbaseTx ¶ added in v1.0.16
func (itx *ImportTx) SetCoinbaseTx(tx *types.Transaction) error
type VMI ¶
type VMI interface { VerifyTx(tx consensus.Tx) (int64, error) VerifyTxSanity(tx consensus.Tx) error GetVM(id string) (consensus.ChainVM, error) CheckConnectBlock(block *types.SerializedBlock) error ConnectBlock(block *types.SerializedBlock) error DisconnectBlock(block *types.SerializedBlock) error AddTxToMempool(tx *types.Transaction, local bool) (int64, error) RemoveTxFromMempool(tx *types.Transaction) error GetTxsFromMempool() ([]*types.Transaction, error) GetMempoolSize() int64 ResetTemplate() error Genesis(txs []*types.Tx) *hash.Hash }
type VMTx ¶
type VMTx struct { *Tx *types.Transaction // contains filtered or unexported fields }
func (*VMTx) CheckSanity ¶
func (*VMTx) SetCoinbaseTx ¶
func (vt *VMTx) SetCoinbaseTx(tx *types.Transaction) error
Source Files ¶
Click to show internal directories.
Click to hide internal directories.