Wildmeshing Toolkit
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
wmtk::threading::task_group::task_job< Fn > Class Template Referencefinal

A task of this group, queued on the pool. Move-only tasks are fine. More...

Inheritance diagram for wmtk::threading::task_group::task_job< Fn >:
wmtk::threading::detail::job

Public Member Functions

template<typename G >
 task_job (task_group &group, G &&fn)
 
void run () noexcept override
 Runs the task and destroys its state. Never throws.
 
void finish () noexcept override
 

Private Attributes

task_group & m_group
 
std::optional< Fn > m_fn
 

Detailed Description

template<typename Fn>
class wmtk::threading::task_group::task_job< Fn >

A task of this group, queued on the pool. Move-only tasks are fine.

Member Function Documentation

◆ finish()

template<typename Fn >
void wmtk::threading::task_group::task_job< Fn >::finish ( )
inlineoverridevirtualnoexcept

Reports the task finished. Called after run(), once the worker that ran it is idle again. Never throws.

Implements wmtk::threading::detail::job.

◆ run()

template<typename Fn >
void wmtk::threading::task_group::task_job< Fn >::run ( )
inlineoverridevirtualnoexcept

Runs the task and destroys its state. Never throws.

Implements wmtk::threading::detail::job.


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