ThreadSchedule 4.1.0
Modern C++ thread management library
Loading...
Searching...
No Matches
threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info Class Reference

#include <scheduled_pool_backend_base.hpp>

Public Types

enum class  kind : std::uint8_t { one_shot , periodic }

Public Member Functions

auto type () const noexcept -> kind
auto cancellation () const noexcept -> std::shared_ptr< detail::scheduled_cancellation_state > const &
auto periodic_state () const noexcept -> std::shared_ptr< periodic_task_state > const &
auto take_one_shot () noexcept -> one_shot_task_type
auto next_run () const noexcept -> time_point
void advance (time_point now)

Static Public Member Functions

static auto one_shot (std::uint64_t id, time_point run_time, one_shot_task_type task, std::shared_ptr< detail::scheduled_cancellation_state > cancellation) -> scheduled_task_info
static auto periodic (std::uint64_t id, time_point run_time, duration interval, periodic_task_type task, std::shared_ptr< detail::scheduled_cancellation_state > cancellation) -> scheduled_task_info

Detailed Description

template<typename PoolType = thread_pool_backend>
class threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info

Definition at line 143 of file scheduled_pool_backend_base.hpp.

Member Enumeration Documentation

◆ kind

template<typename PoolType = thread_pool_backend>
enum class threadschedule::detail::scheduled_pool_backend_base::scheduled_task_info::kind : std::uint8_t
strong
Enumerator
one_shot 
periodic 

Definition at line 146 of file scheduled_pool_backend_base.hpp.

Member Function Documentation

◆ advance()

template<typename PoolType = thread_pool_backend>
void threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info::advance ( time_point now)
inline

◆ cancellation()

template<typename PoolType = thread_pool_backend>
auto threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info::cancellation ( ) const->std::shared_ptr< detail::scheduled_cancellation_state >const &
inlinenodiscardnoexcept

Definition at line 174 of file scheduled_pool_backend_base.hpp.

Referenced by one_shot(), and periodic().

◆ next_run()

template<typename PoolType = thread_pool_backend>
auto threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info::next_run ( ) const->time_point
inlinenodiscardnoexcept

Definition at line 189 of file scheduled_pool_backend_base.hpp.

◆ one_shot()

template<typename PoolType = thread_pool_backend>
auto threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info::one_shot ( std::uint64_t id,
time_point run_time,
one_shot_task_type task,
std::shared_ptr< detail::scheduled_cancellation_state > cancellation )->scheduled_task_info
inlinestaticnodiscard

Definition at line 153 of file scheduled_pool_backend_base.hpp.

References cancellation().

◆ periodic()

template<typename PoolType = thread_pool_backend>
auto threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info::periodic ( std::uint64_t id,
time_point run_time,
duration interval,
periodic_task_type task,
std::shared_ptr< detail::scheduled_cancellation_state > cancellation )->scheduled_task_info
inlinestaticnodiscard

Definition at line 160 of file scheduled_pool_backend_base.hpp.

References cancellation().

◆ periodic_state()

template<typename PoolType = thread_pool_backend>
auto threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info::periodic_state ( ) const->std::shared_ptr< periodic_task_state >const &
inlinenodiscardnoexcept

Definition at line 179 of file scheduled_pool_backend_base.hpp.

◆ take_one_shot()

template<typename PoolType = thread_pool_backend>
auto threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info::take_one_shot ( ) ->one_shot_task_type
inlinenodiscardnoexcept

Definition at line 184 of file scheduled_pool_backend_base.hpp.

◆ type()

template<typename PoolType = thread_pool_backend>
auto threadschedule::detail::scheduled_pool_backend_base< PoolType >::scheduled_task_info::type ( ) const->kind
inlinenodiscardnoexcept

Definition at line 169 of file scheduled_pool_backend_base.hpp.


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