Horizon Official Technical Documentation
FunctionWrapper Class Reference

#include <WorkerThreadPool.hpp>

Classes

struct  impl_base
 
struct  impl_type
 

Public Member Functions

template<typename F >
 FunctionWrapper (F &&f)
 
void call ()
 
 FunctionWrapper (FunctionWrapper &&other)
 
FunctionWrapperoperator= (FunctionWrapper &&other)
 
 FunctionWrapper (const FunctionWrapper &)=delete
 
 FunctionWrapper (FunctionWrapper &)=delete
 
FunctionWrapperoperator= (const FunctionWrapper &)=delete
 

Private Attributes

std::unique_ptr< impl_baseimpl
 

Constructor & Destructor Documentation

◆ FunctionWrapper() [1/4]

template<typename F >
FunctionWrapper::FunctionWrapper ( F &&  f)
inline
56 : impl(new impl_type<F>(std::move(f)))
57 {}
std::unique_ptr< impl_base > impl
Definition: WorkerThreadPool.hpp:76

◆ FunctionWrapper() [2/4]

FunctionWrapper::FunctionWrapper ( FunctionWrapper &&  other)
inline
62 : impl(std::move(other.impl))
63 {}

◆ FunctionWrapper() [3/4]

FunctionWrapper::FunctionWrapper ( const FunctionWrapper )
delete

◆ FunctionWrapper() [4/4]

FunctionWrapper::FunctionWrapper ( FunctionWrapper )
delete

Member Function Documentation

◆ call()

void FunctionWrapper::call ( )
inline
59{ impl->call(); }

References impl.

◆ operator=() [1/2]

FunctionWrapper & FunctionWrapper::operator= ( const FunctionWrapper )
delete

◆ operator=() [2/2]

FunctionWrapper & FunctionWrapper::operator= ( FunctionWrapper &&  other)
inline
66 {
67 impl = std::move(other.impl);
68 return *this;
69 }

References impl.

Member Data Documentation

◆ impl

std::unique_ptr<impl_base> FunctionWrapper::impl
private

Referenced by call(), and operator=().


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