CatapultServer  v0.5.0.1 (Elephant)
catapult::harvesting::ScheduledHarvesterTask Class Reference

Class that lets a harvester create a block and supplies the block to a consumer. More...

Public Types

using TaskOptions = ScheduledHarvesterTaskOptions
 

Public Member Functions

 ScheduledHarvesterTask (const ScheduledHarvesterTaskOptions &options, std::unique_ptr< Harvester > &&pHarvester)
 Creates a scheduled harvesting task around options and a pHarvester. More...
 
void harvest ()
 

Private Attributes

const decltype(TaskOptions::HarvestingAllowedm_harvestingAllowed
 
const decltype(TaskOptions::LastBlockElementSupplierm_lastBlockElementSupplier
 
const decltype(TaskOptions::TimeSupplierm_timeSupplier
 
const decltype(TaskOptions::RangeConsumerm_rangeConsumer
 
std::unique_ptr< Harvesterm_pHarvester
 
std::atomic_bool m_isAnyHarvestedBlockPending
 

Detailed Description

Class that lets a harvester create a block and supplies the block to a consumer.

Member Typedef Documentation

◆ TaskOptions

Constructor & Destructor Documentation

◆ ScheduledHarvesterTask()

catapult::harvesting::ScheduledHarvesterTask::ScheduledHarvesterTask ( const ScheduledHarvesterTaskOptions options,
std::unique_ptr< Harvester > &&  pHarvester 
)
inlineexplicit

Creates a scheduled harvesting task around options and a pHarvester.

Member Function Documentation

◆ harvest()

void catapult::harvesting::ScheduledHarvesterTask::harvest ( )

Triggers the harvesting process and in case of successfull block creation supplies the block to the consumer.

Here is the call graph for this function:

Member Data Documentation

◆ m_harvestingAllowed

const decltype(TaskOptions::HarvestingAllowed) catapult::harvesting::ScheduledHarvesterTask::m_harvestingAllowed
private

◆ m_isAnyHarvestedBlockPending

std::atomic_bool catapult::harvesting::ScheduledHarvesterTask::m_isAnyHarvestedBlockPending
private

◆ m_lastBlockElementSupplier

const decltype(TaskOptions::LastBlockElementSupplier) catapult::harvesting::ScheduledHarvesterTask::m_lastBlockElementSupplier
private

◆ m_pHarvester

std::unique_ptr<Harvester> catapult::harvesting::ScheduledHarvesterTask::m_pHarvester
private

◆ m_rangeConsumer

const decltype(TaskOptions::RangeConsumer) catapult::harvesting::ScheduledHarvesterTask::m_rangeConsumer
private

◆ m_timeSupplier

const decltype(TaskOptions::TimeSupplier) catapult::harvesting::ScheduledHarvesterTask::m_timeSupplier
private

The documentation for this class was generated from the following files: