Add Block.Creator and Block.Nonce
This commit is contained in:
parent
9d0a08fe5d
commit
652b633e71
@ -400,6 +400,20 @@
|
|||||||
<td><p>区块的哈希,当区块处于待确认状态时为`null` </p></td>
|
<td><p>区块的哈希,当区块处于待确认状态时为`null` </p></td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td>creator</td>
|
||||||
|
<td><a href="#bytes">bytes</a></td>
|
||||||
|
<td></td>
|
||||||
|
<td><p>产块者账户地址 </p></td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td>nonce</td>
|
||||||
|
<td><a href="#uint64">uint64</a></td>
|
||||||
|
<td></td>
|
||||||
|
<td><p>这个区块之前产块者产生的区块数量 </p></td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
<tr>
|
<tr>
|
||||||
<td>parent_hashes</td>
|
<td>parent_hashes</td>
|
||||||
<td><a href="#bytes">bytes</a></td>
|
<td><a href="#bytes">bytes</a></td>
|
||||||
|
@ -127,6 +127,26 @@
|
|||||||
"ismap": false,
|
"ismap": false,
|
||||||
"defaultValue": ""
|
"defaultValue": ""
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "creator",
|
||||||
|
"description": "产块者账户地址",
|
||||||
|
"label": "",
|
||||||
|
"type": "bytes",
|
||||||
|
"longType": "bytes",
|
||||||
|
"fullType": "bytes",
|
||||||
|
"ismap": false,
|
||||||
|
"defaultValue": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "nonce",
|
||||||
|
"description": "这个区块之前产块者产生的区块数量",
|
||||||
|
"label": "",
|
||||||
|
"type": "uint64",
|
||||||
|
"longType": "uint64",
|
||||||
|
"fullType": "uint64",
|
||||||
|
"ismap": false,
|
||||||
|
"defaultValue": ""
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "parent_hashes",
|
"name": "parent_hashes",
|
||||||
"description": "父区块的哈希",
|
"description": "父区块的哈希",
|
||||||
|
@ -92,6 +92,8 @@
|
|||||||
| Field | Type | Label | Description |
|
| Field | Type | Label | Description |
|
||||||
| ----- | ---- | ----- | ----------- |
|
| ----- | ---- | ----- | ----------- |
|
||||||
| hash | [bytes](#bytes) | | 区块的哈希,当区块处于待确认状态时为`null` |
|
| hash | [bytes](#bytes) | | 区块的哈希,当区块处于待确认状态时为`null` |
|
||||||
|
| creator | [bytes](#bytes) | | 产块者账户地址 |
|
||||||
|
| nonce | [uint64](#uint64) | | 这个区块之前产块者产生的区块数量 |
|
||||||
| parent_hashes | [bytes](#bytes) | repeated | 父区块的哈希 |
|
| parent_hashes | [bytes](#bytes) | repeated | 父区块的哈希 |
|
||||||
| witnesses | [bytes](#bytes) | repeated | 见证者账户地址 |
|
| witnesses | [bytes](#bytes) | repeated | 见证者账户地址 |
|
||||||
| timestamp | [int64](#int64) | | 区块产生时的 UNIX 时间戳,单位为秒 |
|
| timestamp | [int64](#int64) | | 区块产生时的 UNIX 时间戳,单位为秒 |
|
||||||
|
@ -29,15 +29,17 @@ message Transaction {
|
|||||||
}
|
}
|
||||||
|
|
||||||
message Block {
|
message Block {
|
||||||
bytes hash = 1; // 区块的哈希,当区块处于待确认状态时为`null`
|
bytes hash = 1; // 区块的哈希,当区块处于待确认状态时为`null`
|
||||||
repeated bytes parent_hashes = 2; // 父区块的哈希
|
bytes creator = 2; // 产块者账户地址
|
||||||
repeated bytes witnesses = 3; // 见证者账户地址
|
uint64 nonce = 3; // 这个区块之前产块者产生的区块数量
|
||||||
int64 timestamp = 4; // 区块产生时的 UNIX 时间戳,单位为秒
|
repeated bytes parent_hashes = 4; // 父区块的哈希
|
||||||
uint64 size = 5; // 区块大小的字节数
|
repeated bytes witnesses = 5; // 见证者账户地址
|
||||||
uint32 transaction_count = 6; // 区块包含的事务数量
|
int64 timestamp = 6; // 区块产生时的 UNIX 时间戳,单位为秒
|
||||||
bytes transactions_root = 7; // 区块的事务默克尔树根
|
uint64 size = 7; // 区块大小的字节数
|
||||||
repeated Transaction transactions = 8; // 事务对象的数组,或为空
|
uint32 transaction_count = 8; // 区块包含的事务数量
|
||||||
repeated bytes transaction_hashes = 9; // 20字节的交易哈希的数组,或为空
|
bytes transactions_root = 9; // 区块的事务默克尔树根
|
||||||
|
repeated Transaction transactions = 10; // 事务对象的数组,或为空
|
||||||
|
repeated bytes transaction_hashes = 11; // 20字节的交易哈希的数组,或为空
|
||||||
}
|
}
|
||||||
|
|
||||||
message Contract {
|
message Contract {
|
||||||
|
Loading…
Reference in New Issue
Block a user