可以在智能合约里面查询某个区块号是由哪个矿工挖到的吗?或者有目前智能合约可以看到区块链哪些信息的文档吗?
发布于 12 天前 作者 15622149705 72 次浏览 来自 智能合约

如题~

1 回复

Block and Transaction Properties block.blockhash(uint blockNumber) returns (bytes32): hash of the given block - only works for 256 most recent blocks excluding current block.coinbase (address): current block miner’s address block.difficulty (uint): current block difficulty block.gaslimit (uint): current block gaslimit block.number (uint): current block number block.timestamp (uint): current block timestamp as seconds since unix epoch msg.data (bytes): complete calldata msg.gas (uint): remaining gas msg.sender (address): sender of the message (current call) msg.sig (bytes4): first four bytes of the calldata (i.e. function identifier) msg.value (uint): number of wei sent with the message now (uint): current block timestamp (alias for block.timestamp) tx.gasprice (uint): gas price of the transaction tx.origin (address): sender of the transaction (full call chain)

回到顶部