ipld-eth-server/pkg/core/blockchain.go

16 lines
439 B
Go
Raw Normal View History

package core
import "math/big"
type Blockchain interface {
GetBlockByNumber(blockNumber int64) Block
LastBlock() *big.Int
Node() Node
SubscribeToBlocks(blocks chan Block)
StartListening()
StopListening()
2017-12-04 22:54:35 +00:00
GetAttributes(contract Contract) (ContractAttributes, error)
GetAttribute(contract Contract, attributeName string, blockNumber *big.Int) (interface{}, error)
GetLogs(contract Contract, blockNumber *big.Int) ([]Log, error)
}