| 926 | } |
| 927 | |
| 928 | std::unique_ptr<BlockTemplate> waitNext(BlockWaitOptions options) override |
| 929 | { |
| 930 | auto new_template = WaitAndCreateNewBlock(chainman(), |
| 931 | notifications(), |
| 932 | m_node.mempool.get(), |
| 933 | m_block_template, |
| 934 | /*wait_options=*/options, |
| 935 | /*create_options=*/m_create_options, |
| 936 | /*interrupt_wait=*/m_interrupt_wait); |
| 937 | if (new_template) return std::make_unique<BlockTemplateImpl>(m_create_options, std::move(new_template), m_node); |
| 938 | return nullptr; |
| 939 | } |
| 940 | |
| 941 | void interruptWait() override |
| 942 | { |