update statistics (does not update nSize) */
| 85 | |
| 86 | /** update statistics (does not update nSize) */ |
| 87 | void AddBlock(unsigned int nHeightIn, uint64_t nTimeIn) |
| 88 | { |
| 89 | if (nBlocks == 0 || nHeightFirst > nHeightIn) |
| 90 | nHeightFirst = nHeightIn; |
| 91 | if (nBlocks == 0 || nTimeFirst > nTimeIn) |
| 92 | nTimeFirst = nTimeIn; |
| 93 | nBlocks++; |
| 94 | if (nHeightIn > nHeightLast) |
| 95 | nHeightLast = nHeightIn; |
| 96 | if (nTimeIn > nTimeLast) |
| 97 | nTimeLast = nTimeIn; |
| 98 | } |
| 99 | }; |
| 100 | |
| 101 | enum BlockStatus : uint32_t { |