WPILibC++ 2023.4.3
wpi::uv::WorkReq Class Reference

Work request. More...

#include <wpinet/uv/Work.h>

Inheritance diagram for wpi::uv::WorkReq:
wpi::uv::RequestImpl< WorkReq, uv_work_t > wpi::uv::Request

Public Member Functions

 WorkReq ()
 
LoopGetLoop () const
 
- Public Member Functions inherited from wpi::uv::RequestImpl< WorkReq, uv_work_t >
std::shared_ptr< WorkReqshared_from_this ()
 
std::shared_ptr< const WorkReqshared_from_this () const
 
uv_work_tGetRaw () noexcept
 Get the underlying request data structure. More...
 
const uv_work_tGetRaw () const noexcept
 Get the underlying request data structure. More...
 
- Public Member Functions inherited from wpi::uv::Request
 Request (const Request &)=delete
 
 Request (Request &&)=delete
 
Requestoperator= (const Request &)=delete
 
Requestoperator= (Request &&)=delete
 
virtual ~Request () noexcept=default
 
Type GetType () const noexcept
 Get the type of the request. More...
 
const char * GetTypeName () const noexcept
 Get the name of the type of the request. More...
 
bool Cancel ()
 Cancel a pending request. More...
 
size_t RawSize () const noexcept
 Return the size of the underlying request type. More...
 
uv_req_tGetRawReq () noexcept
 Get the underlying request data structure. More...
 
const uv_req_tGetRawReq () const noexcept
 Get the underlying request data structure. More...
 
virtual void Keep () noexcept
 Keep this request in memory even if no outside shared_ptr references remain. More...
 
virtual void Release () noexcept
 No longer force holding this request in memory. More...
 
void ReportError (int err)
 Report an error. More...
 

Public Attributes

sig::Signal work
 Function(s) that will be run on the thread pool. More...
 
sig::Signal afterWork
 Function(s) that will be run on the loop thread after the work on the thread pool has been completed by the work callback. More...
 
- Public Attributes inherited from wpi::uv::Request
std::function< void(Error)> error
 Error callback. More...
 

Additional Inherited Members

- Public Types inherited from wpi::uv::Request
using Type = uv_req_type
 
- Protected Member Functions inherited from wpi::uv::RequestImpl< WorkReq, uv_work_t >
 RequestImpl ()
 Constructor. More...
 
- Protected Member Functions inherited from wpi::uv::Request
 Request (uv_req_t *uv_req)
 Constructor. More...
 

Detailed Description

Work request.

For use with QueueWork() function family.

Constructor & Destructor Documentation

◆ WorkReq()

wpi::uv::WorkReq::WorkReq ( )

Member Function Documentation

◆ GetLoop()

Loop & wpi::uv::WorkReq::GetLoop ( ) const
inline

Member Data Documentation

◆ afterWork

sig::Signal wpi::uv::WorkReq::afterWork

Function(s) that will be run on the loop thread after the work on the thread pool has been completed by the work callback.

◆ work

sig::Signal wpi::uv::WorkReq::work

Function(s) that will be run on the thread pool.


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