Ledger Class
Provides a series attributes and methods of the native contract GasToken, which hash is0xda65b600f7124ce6c79950c1772a36403104f2be
.
Namespace:Neo.SmartContract.Framework.Native
Assembly: Neo.SmartContract.Framework
#
Syntaxpublic class Ledger
#
PropertiesName | Description |
---|---|
Hash | Gets the contract hash. |
CurrentHash | Gets hash of the latest block |
CurrentIndex | Gets latest block height in current blockchain Block height = Block index = Block count - 1 |
#
MethodsName | Description |
---|---|
GetBlock() | Gets block by the block hash or index |
GetTransaction(UInt256 hash) | Gets transaction by transaction ID |
GetTransactionFromBlock() | Gets the specified transaction by the block and transaction indexes |
GetTransactionHeight(UInt256 hash) | Gets the block height where the transaction occurs by the transaction hash |