Documentation ¶
Index ¶
- Constants
- Variables
- func CreateChainConfig(connectionType string, connectionUrl string, connectionPort uint64) map[string]interface{}
- type BlockHeader
- type Chain
- type ChainConfig
- type ChainsConfig
- type Client
- func (c Client) Account() string
- func (c Client) Balance(chainId uint8) (*big.Int, error)
- func (c Client) BlockByHash(blockHash common.Hash, chain uint8) (*types.Block, error)
- func (c Client) BlockByNumber(blockNumber uint64, chain uint8) (*types.Block, error)
- func (c Client) BlockHeader(blockHash [32]byte, chain uint8) (BlockHeader, error)
- func (c Client) BlockHeaderExists(blockHash [32]byte, chain uint8) (bool, error)
- func (c Client) Chains() []uint8
- func (c Client) DeployEthash(targetChain uint8) common.Address
- func (c Client) DeployTestimonium(targetChain uint8, sourceChain uint8, genesisBlockNumber uint64) common.Address
- func (c Client) DisputeBlock(blockHash [32]byte, dataSetLookUp []*big.Int, witnessForLookup []*big.Int, ...)
- func (c Client) GenerateMerkleProofForReceipt(txHash [32]byte, chain uint8) ([32]byte, []byte, []byte, []byte, error)
- func (c Client) GenerateMerkleProofForTx(txHash [32]byte, chain uint8) ([32]byte, []byte, []byte, []byte, error)
- func (c Client) HeaderByHash(blockHash common.Hash, chain uint8) (*types.Header, error)
- func (c Client) HeaderByNumber(blockNumber *big.Int, chain uint8) (*types.Header, error)
- func (c Client) OriginalBlockHeader(blockHash [32]byte, chain uint8) (*types.Block, error)
- func (c Client) RandomizeHeader(header *types.Header, chain uint8) *types.Header
- func (c Client) SetEpochData(epochData typedefs.EpochData, chain uint8)
- func (c Client) SubmitHeader(header *types.Header, chain uint8)
- func (c Client) SubmitRLPHeader(rlpHeader []byte, chain uint8)
- func (c Client) TotalBalance() (*big.Int, error)
- func (c Client) TotalDifficulty(blockNumber *big.Int, chain uint8) (*big.Int, error)
- func (c Client) Transaction(txHash common.Hash, chain uint8) (*types.Transaction, bool, error)
- func (c Client) TransactionReceipt(txHash common.Hash, chain uint8) (*types.Receipt, error)
- func (c Client) VerifyMerkleProof(blockHash [32]byte, trieValueType TrieValueType, rlpEncodedValue []byte, ...) bool
- type Testimonium
- type TestimoniumCaller
- func (_Testimonium *TestimoniumCaller) GetBlockHashOfEndpoint(opts *bind.CallOpts, index *big.Int) ([32]byte, error)
- func (_Testimonium *TestimoniumCaller) GetHeader(opts *bind.CallOpts, blockHash [32]byte) (struct{ ... }, error)
- func (_Testimonium *TestimoniumCaller) GetHeaderMetaInfo(opts *bind.CallOpts, blockHash [32]byte) (struct{ ... }, error)
- func (_Testimonium *TestimoniumCaller) GetNoOfForks(opts *bind.CallOpts) (*big.Int, error)
- func (_Testimonium *TestimoniumCaller) IsBlock(opts *bind.CallOpts, hash [32]byte) (bool, error)
- func (_Testimonium *TestimoniumCaller) IsUnlocked(opts *bind.CallOpts, blockHash [32]byte) (bool, error)
- func (_Testimonium *TestimoniumCaller) LongestChainEndpoint(opts *bind.CallOpts) ([32]byte, error)
- func (_Testimonium *TestimoniumCaller) VerifyReceipt(opts *bind.CallOpts, blockHash [32]byte, noOfConfirmations uint8, ...) (uint8, error)
- func (_Testimonium *TestimoniumCaller) VerifyState(opts *bind.CallOpts, blockHash [32]byte, noOfConfirmations uint8, ...) (uint8, error)
- func (_Testimonium *TestimoniumCaller) VerifyTransaction(opts *bind.CallOpts, blockHash [32]byte, noOfConfirmations uint8, ...) (uint8, error)
- type TestimoniumCallerRaw
- type TestimoniumCallerSession
- func (_Testimonium *TestimoniumCallerSession) GetBlockHashOfEndpoint(index *big.Int) ([32]byte, error)
- func (_Testimonium *TestimoniumCallerSession) GetHeader(blockHash [32]byte) (struct{ ... }, error)
- func (_Testimonium *TestimoniumCallerSession) GetHeaderMetaInfo(blockHash [32]byte) (struct{ ... }, error)
- func (_Testimonium *TestimoniumCallerSession) GetNoOfForks() (*big.Int, error)
- func (_Testimonium *TestimoniumCallerSession) IsBlock(hash [32]byte) (bool, error)
- func (_Testimonium *TestimoniumCallerSession) IsUnlocked(blockHash [32]byte) (bool, error)
- func (_Testimonium *TestimoniumCallerSession) LongestChainEndpoint() ([32]byte, error)
- func (_Testimonium *TestimoniumCallerSession) VerifyReceipt(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedReceipt []byte, ...) (uint8, error)
- func (_Testimonium *TestimoniumCallerSession) VerifyState(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedState []byte, ...) (uint8, error)
- func (_Testimonium *TestimoniumCallerSession) VerifyTransaction(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedTx []byte, path []byte, ...) (uint8, error)
- type TestimoniumFilterer
- func (_Testimonium *TestimoniumFilterer) FilterPoWValidationResult(opts *bind.FilterOpts) (*TestimoniumPoWValidationResultIterator, error)
- func (_Testimonium *TestimoniumFilterer) FilterRemoveBranch(opts *bind.FilterOpts) (*TestimoniumRemoveBranchIterator, error)
- func (_Testimonium *TestimoniumFilterer) FilterSubmitBlockHeader(opts *bind.FilterOpts) (*TestimoniumSubmitBlockHeaderIterator, error)
- func (_Testimonium *TestimoniumFilterer) ParsePoWValidationResult(log types.Log) (*TestimoniumPoWValidationResult, error)
- func (_Testimonium *TestimoniumFilterer) ParseRemoveBranch(log types.Log) (*TestimoniumRemoveBranch, error)
- func (_Testimonium *TestimoniumFilterer) ParseSubmitBlockHeader(log types.Log) (*TestimoniumSubmitBlockHeader, error)
- func (_Testimonium *TestimoniumFilterer) WatchPoWValidationResult(opts *bind.WatchOpts, sink chan<- *TestimoniumPoWValidationResult) (event.Subscription, error)
- func (_Testimonium *TestimoniumFilterer) WatchRemoveBranch(opts *bind.WatchOpts, sink chan<- *TestimoniumRemoveBranch) (event.Subscription, error)
- func (_Testimonium *TestimoniumFilterer) WatchSubmitBlockHeader(opts *bind.WatchOpts, sink chan<- *TestimoniumSubmitBlockHeader) (event.Subscription, error)
- type TestimoniumPoWValidationResult
- type TestimoniumPoWValidationResultIterator
- type TestimoniumRaw
- func (_Testimonium *TestimoniumRaw) Call(opts *bind.CallOpts, result interface{}, method string, params ...interface{}) error
- func (_Testimonium *TestimoniumRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)
- func (_Testimonium *TestimoniumRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)
- type TestimoniumRemoveBranch
- type TestimoniumRemoveBranchIterator
- type TestimoniumSession
- func (_Testimonium *TestimoniumSession) DisputeBlock(blockHash [32]byte, dataSetLookup []*big.Int, witnessForLookup []*big.Int) (*types.Transaction, error)
- func (_Testimonium *TestimoniumSession) GetBlockHashOfEndpoint(index *big.Int) ([32]byte, error)
- func (_Testimonium *TestimoniumSession) GetHeader(blockHash [32]byte) (struct{ ... }, error)
- func (_Testimonium *TestimoniumSession) GetHeaderMetaInfo(blockHash [32]byte) (struct{ ... }, error)
- func (_Testimonium *TestimoniumSession) GetNoOfForks() (*big.Int, error)
- func (_Testimonium *TestimoniumSession) IsBlock(hash [32]byte) (bool, error)
- func (_Testimonium *TestimoniumSession) IsUnlocked(blockHash [32]byte) (bool, error)
- func (_Testimonium *TestimoniumSession) LongestChainEndpoint() ([32]byte, error)
- func (_Testimonium *TestimoniumSession) SubmitHeader(_rlpHeader []byte) (*types.Transaction, error)
- func (_Testimonium *TestimoniumSession) VerifyReceipt(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedReceipt []byte, ...) (uint8, error)
- func (_Testimonium *TestimoniumSession) VerifyState(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedState []byte, ...) (uint8, error)
- func (_Testimonium *TestimoniumSession) VerifyTransaction(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedTx []byte, path []byte, ...) (uint8, error)
- type TestimoniumSubmitBlockHeader
- type TestimoniumSubmitBlockHeaderIterator
- type TestimoniumTransactor
- type TestimoniumTransactorRaw
- type TestimoniumTransactorSession
- type TotalDifficulty
- type TrieValueType
Constants ¶
const TestimoniumABI = "" /* 5110-byte string literal not displayed */
TestimoniumABI is the input ABI used to generate the binding from.
Variables ¶
var TestimoniumBin = "" /* 39354-byte string literal not displayed */
TestimoniumBin is the compiled bytecode used for deploying new contracts.
Functions ¶
Types ¶
type BlockHeader ¶
type BlockHeader struct { Parent [32]byte UncleHash [32]byte StateRoot [32]byte TransactionsRoot [32]byte ReceiptsRoot [32]byte BlockNumber *big.Int GasLimit *big.Int RlpHeaderHashWithoutNonce [32]byte Timestamp *big.Int Nonce *big.Int Difficulty *big.Int TotalDifficulty *big.Int }
func (BlockHeader) String ¶
func (header BlockHeader) String() string
type ChainConfig ¶
type ChainConfig map[string]interface{}
type ChainsConfig ¶
type ChainsConfig map[uint8]ChainConfig
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (Client) BlockByHash ¶
func (Client) BlockByNumber ¶
func (Client) BlockHeader ¶
func (c Client) BlockHeader(blockHash [32]byte, chain uint8) (BlockHeader, error)
func (Client) BlockHeaderExists ¶
func (Client) DeployTestimonium ¶
func (Client) DisputeBlock ¶
func (Client) GenerateMerkleProofForReceipt ¶
func (Client) GenerateMerkleProofForTx ¶
func (Client) HeaderByHash ¶
func (Client) HeaderByNumber ¶
func (Client) OriginalBlockHeader ¶
func (Client) RandomizeHeader ¶
func (Client) SetEpochData ¶
func (Client) SubmitRLPHeader ¶
func (Client) TotalDifficulty ¶
func (Client) Transaction ¶
func (Client) TransactionReceipt ¶
type Testimonium ¶
type Testimonium struct { TestimoniumCaller // Read-only binding to the contract TestimoniumTransactor // Write-only binding to the contract TestimoniumFilterer // Log filterer for contract events }
Testimonium is an auto generated Go binding around an Ethereum contract.
func DeployTestimonium ¶
func DeployTestimonium(auth *bind.TransactOpts, backend bind.ContractBackend, _rlpHeader []byte, totalDifficulty *big.Int, _ethashContractAddr common.Address) (common.Address, *types.Transaction, *Testimonium, error)
DeployTestimonium deploys a new Ethereum contract, binding an instance of Testimonium to it.
func NewTestimonium ¶
func NewTestimonium(address common.Address, backend bind.ContractBackend) (*Testimonium, error)
NewTestimonium creates a new instance of Testimonium, bound to a specific deployed contract.
type TestimoniumCaller ¶
type TestimoniumCaller struct {
// contains filtered or unexported fields
}
TestimoniumCaller is an auto generated read-only Go binding around an Ethereum contract.
func NewTestimoniumCaller ¶
func NewTestimoniumCaller(address common.Address, caller bind.ContractCaller) (*TestimoniumCaller, error)
NewTestimoniumCaller creates a new read-only instance of Testimonium, bound to a specific deployed contract.
func (*TestimoniumCaller) GetBlockHashOfEndpoint ¶
func (_Testimonium *TestimoniumCaller) GetBlockHashOfEndpoint(opts *bind.CallOpts, index *big.Int) ([32]byte, error)
GetBlockHashOfEndpoint is a free data retrieval call binding the contract method 0x84bc44b3.
Solidity: function getBlockHashOfEndpoint(uint256 index) constant returns(bytes32)
func (*TestimoniumCaller) GetHeader ¶
func (_Testimonium *TestimoniumCaller) GetHeader(opts *bind.CallOpts, blockHash [32]byte) (struct { Parent [32]byte UncleHash [32]byte StateRoot [32]byte TransactionsRoot [32]byte ReceiptsRoot [32]byte BlockNumber *big.Int GasLimit *big.Int RlpHeaderHashWithoutNonce [32]byte Timestamp *big.Int Nonce *big.Int Difficulty *big.Int TotalDifficulty *big.Int }, error)
GetHeader is a free data retrieval call binding the contract method 0xb9615878.
Solidity: function getHeader(bytes32 blockHash) constant returns(bytes32 parent, bytes32 uncleHash, bytes32 stateRoot, bytes32 transactionsRoot, bytes32 receiptsRoot, uint256 blockNumber, uint256 gasLimit, bytes32 rlpHeaderHashWithoutNonce, uint256 timestamp, uint256 nonce, uint256 difficulty, uint256 totalDifficulty)
func (*TestimoniumCaller) GetHeaderMetaInfo ¶
func (_Testimonium *TestimoniumCaller) GetHeaderMetaInfo(opts *bind.CallOpts, blockHash [32]byte) (struct { Successors [][32]byte OrderedIndex *big.Int IterableIndex *big.Int LatestFork [32]byte LockedUntil *big.Int }, error)
GetHeaderMetaInfo is a free data retrieval call binding the contract method 0x3b93fc10.
Solidity: function getHeaderMetaInfo(bytes32 blockHash) constant returns(bytes32[] successors, uint256 orderedIndex, uint256 iterableIndex, bytes32 latestFork, uint256 lockedUntil)
func (*TestimoniumCaller) GetNoOfForks ¶
GetNoOfForks is a free data retrieval call binding the contract method 0xfbb5df38.
Solidity: function getNoOfForks() constant returns(uint256)
func (*TestimoniumCaller) IsBlock ¶
IsBlock is a free data retrieval call binding the contract method 0x528a309f.
Solidity: function isBlock(bytes32 hash) constant returns(bool)
func (*TestimoniumCaller) IsUnlocked ¶
func (_Testimonium *TestimoniumCaller) IsUnlocked(opts *bind.CallOpts, blockHash [32]byte) (bool, error)
IsUnlocked is a free data retrieval call binding the contract method 0x3dadc1e1.
Solidity: function isUnlocked(bytes32 blockHash) constant returns(bool)
func (*TestimoniumCaller) LongestChainEndpoint ¶
func (_Testimonium *TestimoniumCaller) LongestChainEndpoint(opts *bind.CallOpts) ([32]byte, error)
LongestChainEndpoint is a free data retrieval call binding the contract method 0x0aa7fc0f.
Solidity: function longestChainEndpoint() constant returns(bytes32)
func (*TestimoniumCaller) VerifyReceipt ¶
func (_Testimonium *TestimoniumCaller) VerifyReceipt(opts *bind.CallOpts, blockHash [32]byte, noOfConfirmations uint8, rlpEncodedReceipt []byte, path []byte, rlpEncodedNodes []byte) (uint8, error)
VerifyReceipt is a free data retrieval call binding the contract method 0x10fa6e83.
Solidity: function verifyReceipt(bytes32 blockHash, uint8 noOfConfirmations, bytes rlpEncodedReceipt, bytes path, bytes rlpEncodedNodes) constant returns(uint8)
func (*TestimoniumCaller) VerifyState ¶
func (_Testimonium *TestimoniumCaller) VerifyState(opts *bind.CallOpts, blockHash [32]byte, noOfConfirmations uint8, rlpEncodedState []byte, path []byte, rlpEncodedNodes []byte) (uint8, error)
VerifyState is a free data retrieval call binding the contract method 0xfadfdb81.
Solidity: function verifyState(bytes32 blockHash, uint8 noOfConfirmations, bytes rlpEncodedState, bytes path, bytes rlpEncodedNodes) constant returns(uint8)
func (*TestimoniumCaller) VerifyTransaction ¶
func (_Testimonium *TestimoniumCaller) VerifyTransaction(opts *bind.CallOpts, blockHash [32]byte, noOfConfirmations uint8, rlpEncodedTx []byte, path []byte, rlpEncodedNodes []byte) (uint8, error)
VerifyTransaction is a free data retrieval call binding the contract method 0xa90a51f4.
Solidity: function verifyTransaction(bytes32 blockHash, uint8 noOfConfirmations, bytes rlpEncodedTx, bytes path, bytes rlpEncodedNodes) constant returns(uint8)
type TestimoniumCallerRaw ¶
type TestimoniumCallerRaw struct {
Contract *TestimoniumCaller // Generic read-only contract binding to access the raw methods on
}
TestimoniumCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
func (*TestimoniumCallerRaw) Call ¶
func (_Testimonium *TestimoniumCallerRaw) Call(opts *bind.CallOpts, result interface{}, method string, params ...interface{}) error
Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.
type TestimoniumCallerSession ¶
type TestimoniumCallerSession struct { Contract *TestimoniumCaller // Generic contract caller binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session }
TestimoniumCallerSession is an auto generated read-only Go binding around an Ethereum contract, with pre-set call options.
func (*TestimoniumCallerSession) GetBlockHashOfEndpoint ¶
func (_Testimonium *TestimoniumCallerSession) GetBlockHashOfEndpoint(index *big.Int) ([32]byte, error)
GetBlockHashOfEndpoint is a free data retrieval call binding the contract method 0x84bc44b3.
Solidity: function getBlockHashOfEndpoint(uint256 index) constant returns(bytes32)
func (*TestimoniumCallerSession) GetHeader ¶
func (_Testimonium *TestimoniumCallerSession) GetHeader(blockHash [32]byte) (struct { Parent [32]byte UncleHash [32]byte StateRoot [32]byte TransactionsRoot [32]byte ReceiptsRoot [32]byte BlockNumber *big.Int GasLimit *big.Int RlpHeaderHashWithoutNonce [32]byte Timestamp *big.Int Nonce *big.Int Difficulty *big.Int TotalDifficulty *big.Int }, error)
GetHeader is a free data retrieval call binding the contract method 0xb9615878.
Solidity: function getHeader(bytes32 blockHash) constant returns(bytes32 parent, bytes32 uncleHash, bytes32 stateRoot, bytes32 transactionsRoot, bytes32 receiptsRoot, uint256 blockNumber, uint256 gasLimit, bytes32 rlpHeaderHashWithoutNonce, uint256 timestamp, uint256 nonce, uint256 difficulty, uint256 totalDifficulty)
func (*TestimoniumCallerSession) GetHeaderMetaInfo ¶
func (_Testimonium *TestimoniumCallerSession) GetHeaderMetaInfo(blockHash [32]byte) (struct { Successors [][32]byte OrderedIndex *big.Int IterableIndex *big.Int LatestFork [32]byte LockedUntil *big.Int }, error)
GetHeaderMetaInfo is a free data retrieval call binding the contract method 0x3b93fc10.
Solidity: function getHeaderMetaInfo(bytes32 blockHash) constant returns(bytes32[] successors, uint256 orderedIndex, uint256 iterableIndex, bytes32 latestFork, uint256 lockedUntil)
func (*TestimoniumCallerSession) GetNoOfForks ¶
func (_Testimonium *TestimoniumCallerSession) GetNoOfForks() (*big.Int, error)
GetNoOfForks is a free data retrieval call binding the contract method 0xfbb5df38.
Solidity: function getNoOfForks() constant returns(uint256)
func (*TestimoniumCallerSession) IsBlock ¶
func (_Testimonium *TestimoniumCallerSession) IsBlock(hash [32]byte) (bool, error)
IsBlock is a free data retrieval call binding the contract method 0x528a309f.
Solidity: function isBlock(bytes32 hash) constant returns(bool)
func (*TestimoniumCallerSession) IsUnlocked ¶
func (_Testimonium *TestimoniumCallerSession) IsUnlocked(blockHash [32]byte) (bool, error)
IsUnlocked is a free data retrieval call binding the contract method 0x3dadc1e1.
Solidity: function isUnlocked(bytes32 blockHash) constant returns(bool)
func (*TestimoniumCallerSession) LongestChainEndpoint ¶
func (_Testimonium *TestimoniumCallerSession) LongestChainEndpoint() ([32]byte, error)
LongestChainEndpoint is a free data retrieval call binding the contract method 0x0aa7fc0f.
Solidity: function longestChainEndpoint() constant returns(bytes32)
func (*TestimoniumCallerSession) VerifyReceipt ¶
func (_Testimonium *TestimoniumCallerSession) VerifyReceipt(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedReceipt []byte, path []byte, rlpEncodedNodes []byte) (uint8, error)
VerifyReceipt is a free data retrieval call binding the contract method 0x10fa6e83.
Solidity: function verifyReceipt(bytes32 blockHash, uint8 noOfConfirmations, bytes rlpEncodedReceipt, bytes path, bytes rlpEncodedNodes) constant returns(uint8)
func (*TestimoniumCallerSession) VerifyState ¶
func (_Testimonium *TestimoniumCallerSession) VerifyState(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedState []byte, path []byte, rlpEncodedNodes []byte) (uint8, error)
VerifyState is a free data retrieval call binding the contract method 0xfadfdb81.
Solidity: function verifyState(bytes32 blockHash, uint8 noOfConfirmations, bytes rlpEncodedState, bytes path, bytes rlpEncodedNodes) constant returns(uint8)
func (*TestimoniumCallerSession) VerifyTransaction ¶
func (_Testimonium *TestimoniumCallerSession) VerifyTransaction(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedTx []byte, path []byte, rlpEncodedNodes []byte) (uint8, error)
VerifyTransaction is a free data retrieval call binding the contract method 0xa90a51f4.
Solidity: function verifyTransaction(bytes32 blockHash, uint8 noOfConfirmations, bytes rlpEncodedTx, bytes path, bytes rlpEncodedNodes) constant returns(uint8)
type TestimoniumFilterer ¶
type TestimoniumFilterer struct {
// contains filtered or unexported fields
}
TestimoniumFilterer is an auto generated log filtering Go binding around an Ethereum contract events.
func NewTestimoniumFilterer ¶
func NewTestimoniumFilterer(address common.Address, filterer bind.ContractFilterer) (*TestimoniumFilterer, error)
NewTestimoniumFilterer creates a new log filterer instance of Testimonium, bound to a specific deployed contract.
func (*TestimoniumFilterer) FilterPoWValidationResult ¶
func (_Testimonium *TestimoniumFilterer) FilterPoWValidationResult(opts *bind.FilterOpts) (*TestimoniumPoWValidationResultIterator, error)
FilterPoWValidationResult is a free log retrieval operation binding the contract event 0x808f84bd298b89733055f3b8294b385ed860b67438b792ff9e312c897a2fcd9f.
Solidity: event PoWValidationResult(bool isPoWValid, uint256 errorCode, uint256 errorInfo)
func (*TestimoniumFilterer) FilterRemoveBranch ¶
func (_Testimonium *TestimoniumFilterer) FilterRemoveBranch(opts *bind.FilterOpts) (*TestimoniumRemoveBranchIterator, error)
FilterRemoveBranch is a free log retrieval operation binding the contract event 0xf96ae1a1e71431cfb86761b9cab725aeddab2afdaf76d40d43fc005bdc6555d4.
Solidity: event RemoveBranch(bytes32 root)
func (*TestimoniumFilterer) FilterSubmitBlockHeader ¶
func (_Testimonium *TestimoniumFilterer) FilterSubmitBlockHeader(opts *bind.FilterOpts) (*TestimoniumSubmitBlockHeaderIterator, error)
FilterSubmitBlockHeader is a free log retrieval operation binding the contract event 0x56a7be9848412b60f43fa0c4d4e9bb1d1dec16601d6a291428be09dd76b75951.
Solidity: event SubmitBlockHeader(bytes32 hash, bytes32 hashWithoutNonce, uint256 nonce, uint256 difficulty, bytes32 parent, bytes32 transactionsRoot)
func (*TestimoniumFilterer) ParsePoWValidationResult ¶
func (_Testimonium *TestimoniumFilterer) ParsePoWValidationResult(log types.Log) (*TestimoniumPoWValidationResult, error)
ParsePoWValidationResult is a log parse operation binding the contract event 0x808f84bd298b89733055f3b8294b385ed860b67438b792ff9e312c897a2fcd9f.
Solidity: event PoWValidationResult(bool isPoWValid, uint256 errorCode, uint256 errorInfo)
func (*TestimoniumFilterer) ParseRemoveBranch ¶
func (_Testimonium *TestimoniumFilterer) ParseRemoveBranch(log types.Log) (*TestimoniumRemoveBranch, error)
ParseRemoveBranch is a log parse operation binding the contract event 0xf96ae1a1e71431cfb86761b9cab725aeddab2afdaf76d40d43fc005bdc6555d4.
Solidity: event RemoveBranch(bytes32 root)
func (*TestimoniumFilterer) ParseSubmitBlockHeader ¶
func (_Testimonium *TestimoniumFilterer) ParseSubmitBlockHeader(log types.Log) (*TestimoniumSubmitBlockHeader, error)
ParseSubmitBlockHeader is a log parse operation binding the contract event 0x56a7be9848412b60f43fa0c4d4e9bb1d1dec16601d6a291428be09dd76b75951.
Solidity: event SubmitBlockHeader(bytes32 hash, bytes32 hashWithoutNonce, uint256 nonce, uint256 difficulty, bytes32 parent, bytes32 transactionsRoot)
func (*TestimoniumFilterer) WatchPoWValidationResult ¶
func (_Testimonium *TestimoniumFilterer) WatchPoWValidationResult(opts *bind.WatchOpts, sink chan<- *TestimoniumPoWValidationResult) (event.Subscription, error)
WatchPoWValidationResult is a free log subscription operation binding the contract event 0x808f84bd298b89733055f3b8294b385ed860b67438b792ff9e312c897a2fcd9f.
Solidity: event PoWValidationResult(bool isPoWValid, uint256 errorCode, uint256 errorInfo)
func (*TestimoniumFilterer) WatchRemoveBranch ¶
func (_Testimonium *TestimoniumFilterer) WatchRemoveBranch(opts *bind.WatchOpts, sink chan<- *TestimoniumRemoveBranch) (event.Subscription, error)
WatchRemoveBranch is a free log subscription operation binding the contract event 0xf96ae1a1e71431cfb86761b9cab725aeddab2afdaf76d40d43fc005bdc6555d4.
Solidity: event RemoveBranch(bytes32 root)
func (*TestimoniumFilterer) WatchSubmitBlockHeader ¶
func (_Testimonium *TestimoniumFilterer) WatchSubmitBlockHeader(opts *bind.WatchOpts, sink chan<- *TestimoniumSubmitBlockHeader) (event.Subscription, error)
WatchSubmitBlockHeader is a free log subscription operation binding the contract event 0x56a7be9848412b60f43fa0c4d4e9bb1d1dec16601d6a291428be09dd76b75951.
Solidity: event SubmitBlockHeader(bytes32 hash, bytes32 hashWithoutNonce, uint256 nonce, uint256 difficulty, bytes32 parent, bytes32 transactionsRoot)
type TestimoniumPoWValidationResult ¶
type TestimoniumPoWValidationResult struct { IsPoWValid bool ErrorCode *big.Int ErrorInfo *big.Int Raw types.Log // Blockchain specific contextual infos }
TestimoniumPoWValidationResult represents a PoWValidationResult event raised by the Testimonium contract.
func (TestimoniumPoWValidationResult) String ¶
func (event TestimoniumPoWValidationResult) String() string
type TestimoniumPoWValidationResultIterator ¶
type TestimoniumPoWValidationResultIterator struct { Event *TestimoniumPoWValidationResult // Event containing the contract specifics and raw log // contains filtered or unexported fields }
TestimoniumPoWValidationResultIterator is returned from FilterPoWValidationResult and is used to iterate over the raw logs and unpacked data for PoWValidationResult events raised by the Testimonium contract.
func (*TestimoniumPoWValidationResultIterator) Close ¶
func (it *TestimoniumPoWValidationResultIterator) Close() error
Close terminates the iteration process, releasing any pending underlying resources.
func (*TestimoniumPoWValidationResultIterator) Error ¶
func (it *TestimoniumPoWValidationResultIterator) Error() error
Error returns any retrieval or parsing error occurred during filtering.
func (*TestimoniumPoWValidationResultIterator) Next ¶
func (it *TestimoniumPoWValidationResultIterator) Next() bool
Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.
type TestimoniumRaw ¶
type TestimoniumRaw struct {
Contract *Testimonium // Generic contract binding to access the raw methods on
}
TestimoniumRaw is an auto generated low-level Go binding around an Ethereum contract.
func (*TestimoniumRaw) Call ¶
func (_Testimonium *TestimoniumRaw) Call(opts *bind.CallOpts, result interface{}, method string, params ...interface{}) error
Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.
func (*TestimoniumRaw) Transact ¶
func (_Testimonium *TestimoniumRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)
Transact invokes the (paid) contract method with params as input values.
func (*TestimoniumRaw) Transfer ¶
func (_Testimonium *TestimoniumRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)
Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.
type TestimoniumRemoveBranch ¶
type TestimoniumRemoveBranch struct { Root [32]byte Raw types.Log // Blockchain specific contextual infos }
TestimoniumRemoveBranch represents a RemoveBranch event raised by the Testimonium contract.
func (TestimoniumRemoveBranch) String ¶
func (event TestimoniumRemoveBranch) String() string
type TestimoniumRemoveBranchIterator ¶
type TestimoniumRemoveBranchIterator struct { Event *TestimoniumRemoveBranch // Event containing the contract specifics and raw log // contains filtered or unexported fields }
TestimoniumRemoveBranchIterator is returned from FilterRemoveBranch and is used to iterate over the raw logs and unpacked data for RemoveBranch events raised by the Testimonium contract.
func (*TestimoniumRemoveBranchIterator) Close ¶
func (it *TestimoniumRemoveBranchIterator) Close() error
Close terminates the iteration process, releasing any pending underlying resources.
func (*TestimoniumRemoveBranchIterator) Error ¶
func (it *TestimoniumRemoveBranchIterator) Error() error
Error returns any retrieval or parsing error occurred during filtering.
func (*TestimoniumRemoveBranchIterator) Next ¶
func (it *TestimoniumRemoveBranchIterator) Next() bool
Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.
type TestimoniumSession ¶
type TestimoniumSession struct { Contract *Testimonium // Generic contract binding to set the session for CallOpts bind.CallOpts // Call options to use throughout this session TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session }
TestimoniumSession is an auto generated Go binding around an Ethereum contract, with pre-set call and transact options.
func (*TestimoniumSession) DisputeBlock ¶
func (_Testimonium *TestimoniumSession) DisputeBlock(blockHash [32]byte, dataSetLookup []*big.Int, witnessForLookup []*big.Int) (*types.Transaction, error)
DisputeBlock is a paid mutator transaction binding the contract method 0x66962b26.
Solidity: function disputeBlock(bytes32 blockHash, uint256[] dataSetLookup, uint256[] witnessForLookup) returns()
func (*TestimoniumSession) GetBlockHashOfEndpoint ¶
func (_Testimonium *TestimoniumSession) GetBlockHashOfEndpoint(index *big.Int) ([32]byte, error)
GetBlockHashOfEndpoint is a free data retrieval call binding the contract method 0x84bc44b3.
Solidity: function getBlockHashOfEndpoint(uint256 index) constant returns(bytes32)
func (*TestimoniumSession) GetHeader ¶
func (_Testimonium *TestimoniumSession) GetHeader(blockHash [32]byte) (struct { Parent [32]byte UncleHash [32]byte StateRoot [32]byte TransactionsRoot [32]byte ReceiptsRoot [32]byte BlockNumber *big.Int GasLimit *big.Int RlpHeaderHashWithoutNonce [32]byte Timestamp *big.Int Nonce *big.Int Difficulty *big.Int TotalDifficulty *big.Int }, error)
GetHeader is a free data retrieval call binding the contract method 0xb9615878.
Solidity: function getHeader(bytes32 blockHash) constant returns(bytes32 parent, bytes32 uncleHash, bytes32 stateRoot, bytes32 transactionsRoot, bytes32 receiptsRoot, uint256 blockNumber, uint256 gasLimit, bytes32 rlpHeaderHashWithoutNonce, uint256 timestamp, uint256 nonce, uint256 difficulty, uint256 totalDifficulty)
func (*TestimoniumSession) GetHeaderMetaInfo ¶
func (_Testimonium *TestimoniumSession) GetHeaderMetaInfo(blockHash [32]byte) (struct { Successors [][32]byte OrderedIndex *big.Int IterableIndex *big.Int LatestFork [32]byte LockedUntil *big.Int }, error)
GetHeaderMetaInfo is a free data retrieval call binding the contract method 0x3b93fc10.
Solidity: function getHeaderMetaInfo(bytes32 blockHash) constant returns(bytes32[] successors, uint256 orderedIndex, uint256 iterableIndex, bytes32 latestFork, uint256 lockedUntil)
func (*TestimoniumSession) GetNoOfForks ¶
func (_Testimonium *TestimoniumSession) GetNoOfForks() (*big.Int, error)
GetNoOfForks is a free data retrieval call binding the contract method 0xfbb5df38.
Solidity: function getNoOfForks() constant returns(uint256)
func (*TestimoniumSession) IsBlock ¶
func (_Testimonium *TestimoniumSession) IsBlock(hash [32]byte) (bool, error)
IsBlock is a free data retrieval call binding the contract method 0x528a309f.
Solidity: function isBlock(bytes32 hash) constant returns(bool)
func (*TestimoniumSession) IsUnlocked ¶
func (_Testimonium *TestimoniumSession) IsUnlocked(blockHash [32]byte) (bool, error)
IsUnlocked is a free data retrieval call binding the contract method 0x3dadc1e1.
Solidity: function isUnlocked(bytes32 blockHash) constant returns(bool)
func (*TestimoniumSession) LongestChainEndpoint ¶
func (_Testimonium *TestimoniumSession) LongestChainEndpoint() ([32]byte, error)
LongestChainEndpoint is a free data retrieval call binding the contract method 0x0aa7fc0f.
Solidity: function longestChainEndpoint() constant returns(bytes32)
func (*TestimoniumSession) SubmitHeader ¶
func (_Testimonium *TestimoniumSession) SubmitHeader(_rlpHeader []byte) (*types.Transaction, error)
SubmitHeader is a paid mutator transaction binding the contract method 0xc565ba10.
Solidity: function submitHeader(bytes _rlpHeader) returns()
func (*TestimoniumSession) VerifyReceipt ¶
func (_Testimonium *TestimoniumSession) VerifyReceipt(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedReceipt []byte, path []byte, rlpEncodedNodes []byte) (uint8, error)
VerifyReceipt is a free data retrieval call binding the contract method 0x10fa6e83.
Solidity: function verifyReceipt(bytes32 blockHash, uint8 noOfConfirmations, bytes rlpEncodedReceipt, bytes path, bytes rlpEncodedNodes) constant returns(uint8)
func (*TestimoniumSession) VerifyState ¶
func (_Testimonium *TestimoniumSession) VerifyState(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedState []byte, path []byte, rlpEncodedNodes []byte) (uint8, error)
VerifyState is a free data retrieval call binding the contract method 0xfadfdb81.
Solidity: function verifyState(bytes32 blockHash, uint8 noOfConfirmations, bytes rlpEncodedState, bytes path, bytes rlpEncodedNodes) constant returns(uint8)
func (*TestimoniumSession) VerifyTransaction ¶
func (_Testimonium *TestimoniumSession) VerifyTransaction(blockHash [32]byte, noOfConfirmations uint8, rlpEncodedTx []byte, path []byte, rlpEncodedNodes []byte) (uint8, error)
VerifyTransaction is a free data retrieval call binding the contract method 0xa90a51f4.
Solidity: function verifyTransaction(bytes32 blockHash, uint8 noOfConfirmations, bytes rlpEncodedTx, bytes path, bytes rlpEncodedNodes) constant returns(uint8)
type TestimoniumSubmitBlockHeader ¶
type TestimoniumSubmitBlockHeader struct { Hash [32]byte HashWithoutNonce [32]byte Nonce *big.Int Difficulty *big.Int Parent [32]byte TransactionsRoot [32]byte Raw types.Log // Blockchain specific contextual infos }
TestimoniumSubmitBlockHeader represents a SubmitBlockHeader event raised by the Testimonium contract.
func (TestimoniumSubmitBlockHeader) String ¶
func (t TestimoniumSubmitBlockHeader) String() string
type TestimoniumSubmitBlockHeaderIterator ¶
type TestimoniumSubmitBlockHeaderIterator struct { Event *TestimoniumSubmitBlockHeader // Event containing the contract specifics and raw log // contains filtered or unexported fields }
TestimoniumSubmitBlockHeaderIterator is returned from FilterSubmitBlockHeader and is used to iterate over the raw logs and unpacked data for SubmitBlockHeader events raised by the Testimonium contract.
func (*TestimoniumSubmitBlockHeaderIterator) Close ¶
func (it *TestimoniumSubmitBlockHeaderIterator) Close() error
Close terminates the iteration process, releasing any pending underlying resources.
func (*TestimoniumSubmitBlockHeaderIterator) Error ¶
func (it *TestimoniumSubmitBlockHeaderIterator) Error() error
Error returns any retrieval or parsing error occurred during filtering.
func (*TestimoniumSubmitBlockHeaderIterator) Next ¶
func (it *TestimoniumSubmitBlockHeaderIterator) Next() bool
Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.
type TestimoniumTransactor ¶
type TestimoniumTransactor struct {
// contains filtered or unexported fields
}
TestimoniumTransactor is an auto generated write-only Go binding around an Ethereum contract.
func NewTestimoniumTransactor ¶
func NewTestimoniumTransactor(address common.Address, transactor bind.ContractTransactor) (*TestimoniumTransactor, error)
NewTestimoniumTransactor creates a new write-only instance of Testimonium, bound to a specific deployed contract.
func (*TestimoniumTransactor) DisputeBlock ¶
func (_Testimonium *TestimoniumTransactor) DisputeBlock(opts *bind.TransactOpts, blockHash [32]byte, dataSetLookup []*big.Int, witnessForLookup []*big.Int) (*types.Transaction, error)
DisputeBlock is a paid mutator transaction binding the contract method 0x66962b26.
Solidity: function disputeBlock(bytes32 blockHash, uint256[] dataSetLookup, uint256[] witnessForLookup) returns()
func (*TestimoniumTransactor) SubmitHeader ¶
func (_Testimonium *TestimoniumTransactor) SubmitHeader(opts *bind.TransactOpts, _rlpHeader []byte) (*types.Transaction, error)
SubmitHeader is a paid mutator transaction binding the contract method 0xc565ba10.
Solidity: function submitHeader(bytes _rlpHeader) returns()
type TestimoniumTransactorRaw ¶
type TestimoniumTransactorRaw struct {
Contract *TestimoniumTransactor // Generic write-only contract binding to access the raw methods on
}
TestimoniumTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
func (*TestimoniumTransactorRaw) Transact ¶
func (_Testimonium *TestimoniumTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)
Transact invokes the (paid) contract method with params as input values.
func (*TestimoniumTransactorRaw) Transfer ¶
func (_Testimonium *TestimoniumTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)
Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.
type TestimoniumTransactorSession ¶
type TestimoniumTransactorSession struct { Contract *TestimoniumTransactor // Generic contract transactor binding to set the session for TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session }
TestimoniumTransactorSession is an auto generated write-only Go binding around an Ethereum contract, with pre-set transact options.
func (*TestimoniumTransactorSession) DisputeBlock ¶
func (_Testimonium *TestimoniumTransactorSession) DisputeBlock(blockHash [32]byte, dataSetLookup []*big.Int, witnessForLookup []*big.Int) (*types.Transaction, error)
DisputeBlock is a paid mutator transaction binding the contract method 0x66962b26.
Solidity: function disputeBlock(bytes32 blockHash, uint256[] dataSetLookup, uint256[] witnessForLookup) returns()
func (*TestimoniumTransactorSession) SubmitHeader ¶
func (_Testimonium *TestimoniumTransactorSession) SubmitHeader(_rlpHeader []byte) (*types.Transaction, error)
SubmitHeader is a paid mutator transaction binding the contract method 0xc565ba10.
Solidity: function submitHeader(bytes _rlpHeader) returns()
type TotalDifficulty ¶
type TotalDifficulty struct {
TotalDifficulty string `json:"totalDifficulty" gencodec:"required"`
}
type TrieValueType ¶
type TrieValueType int
const ( VALUE_TYPE_TRANSACTION TrieValueType = 0 VALUE_TYPE_RECEIPT TrieValueType = 1 VALUE_TYPE_STATE TrieValueType = 2 )