join 1.0
lightweight network framework library
Loading...
Searching...
No Matches
join::CompletionHandler Class Reference

completion handler interface class. More...

#include <proactor.hpp>

Inheritance diagram for join::CompletionHandler:

Public Member Functions

 CompletionHandler ()=default
 create instance.
 
 CompletionHandler (const CompletionHandler &other)=default
 copy constructor.
 
CompletionHandleroperator= (const CompletionHandler &other)=default
 copy assignment operator.
 
 CompletionHandler (CompletionHandler &&other)=default
 move constructor.
 
CompletionHandleroperator= (CompletionHandler &&other)=default
 move assignment operator.
 
virtual ~CompletionHandler ()=default
 destroy instance.
 

Protected Member Functions

virtual void onComplete (IoOperation *op, int result)
 method called when an operation completes successfully.
 
virtual void onCancel (IoOperation *op, int result)
 method called when an operation is cancelled.
 

Friends

class join::BasicProactor
 friendship with proactor.
 

Detailed Description

completion handler interface class.

Constructor & Destructor Documentation

◆ CompletionHandler() [1/3]

join::CompletionHandler::CompletionHandler ( )
default

create instance.

◆ CompletionHandler() [2/3]

join::CompletionHandler::CompletionHandler ( const CompletionHandler & other)
default

copy constructor.

Parameters
otherother object to copy.

◆ CompletionHandler() [3/3]

join::CompletionHandler::CompletionHandler ( CompletionHandler && other)
default

move constructor.

Parameters
otherother object to move.

◆ ~CompletionHandler()

virtual join::CompletionHandler::~CompletionHandler ( )
virtualdefault

destroy instance.

Member Function Documentation

◆ onCancel()

virtual void join::CompletionHandler::onCancel ( IoOperation * op,
int result )
inlineprotectedvirtual

method called when an operation is cancelled.

Parameters
opcancelled operation.
result-ECANCELED, or other negative errno on failure.

Reimplemented in HybridProactorTest, ProactorTest, and SqpollProactorTest.

◆ onComplete()

virtual void join::CompletionHandler::onComplete ( IoOperation * op,
int result )
inlineprotectedvirtual

method called when an operation completes successfully.

Parameters
opcompleted operation.
resultnumber of bytes transferred, or operation-specific value.

Reimplemented in HybridProactorTest, ProactorTest, and SqpollProactorTest.

◆ operator=() [1/2]

CompletionHandler & join::CompletionHandler::operator= ( CompletionHandler && other)
default

move assignment operator.

Parameters
otherother object to move.
Returns
current object.

◆ operator=() [2/2]

CompletionHandler & join::CompletionHandler::operator= ( const CompletionHandler & other)
default

copy assignment operator.

Parameters
otherother object to copy.
Returns
current object.

Friends And Related Symbol Documentation

◆ join::BasicProactor

friend class join::BasicProactor
friend

friendship with proactor.


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