Details about a particular Comm IO callback event. More...

#include <IoCallback.h>

Collaboration diagram for Comm::IoCallback:

Public Member Functions

bool active () const
void setCallback (iocb_type type, AsyncCall::Pointer &cb, char *buf, FREE *func, int sz)
void selectOrQueueWrite ()
 called when fd needs to write but may need to wait in line for its quota More...
void cancel (const char *reason)
 Actively cancel the given callback. More...
void finish (Comm::Flag code, int xerrn)
 finish the IO operation imediately and schedule the callback with the current state. More...

Public Attributes

iocb_type type
Comm::ConnectionPointer conn
AsyncCall::Pointer callback
char * buf
int size
int offset
Comm::Flag errcode
int xerrno
unsigned int quotaQueueReserv
 reservation ID from CommQuotaQueue More...

Private Member Functions

void reset ()

Detailed Description

Definition at line 29 of file IoCallback.h.

Member Function Documentation

◆ active()

bool Comm::IoCallback::active ( ) const

◆ cancel()

void Comm::IoCallback::cancel ( const char *  reason)

Definition at line 82 of file

References active(), callback, AsyncCall::cancel(), NULL, and reset().

Referenced by active(), comm_read_cancel(), and Comm::ReadCancel().

◆ finish()

void Comm::IoCallback::finish ( Comm::Flag  code,
int  xerrn 

◆ reset()

void Comm::IoCallback::reset ( )

Definition at line 93 of file

References buf, conn, freefunc, NULL, quotaQueueReserv, and xerrno.

Referenced by active(), cancel(), and finish().

◆ selectOrQueueWrite()

void Comm::IoCallback::selectOrQueueWrite ( )

◆ setCallback()

void Comm::IoCallback::setCallback ( Comm::iocb_type  t,
AsyncCall::Pointer cb,
char *  b,
int  sz 

Configure Comm::Callback for I/O

tIO callback type (read or write)
bufbuffer, if applicable
funcfreefunc, if applicable
szbuffer size

Definition at line 55 of file

References active(), assert, buf, callback, freefunc, NULL, offset, size, sz, and type.

Referenced by active().

Member Data Documentation

◆ buf

char* Comm::IoCallback::buf

Definition at line 35 of file IoCallback.h.

Referenced by finish(), reset(), setCallback(), and Comm::Write().

◆ callback

AsyncCall::Pointer Comm::IoCallback::callback

Definition at line 34 of file IoCallback.h.

Referenced by cancel(), comm_read_cancel(), finish(), Comm::ReadCancel(), and setCallback().

◆ conn

◆ errcode

Comm::Flag Comm::IoCallback::errcode

Definition at line 39 of file IoCallback.h.

◆ freefunc

FREE* Comm::IoCallback::freefunc

Definition at line 36 of file IoCallback.h.

Referenced by finish(), reset(), and setCallback().

◆ offset

int Comm::IoCallback::offset

Definition at line 38 of file IoCallback.h.

Referenced by finish(), setCallback(), and Comm::Write().

◆ quotaQueueReserv

unsigned int Comm::IoCallback::quotaQueueReserv

◆ size

int Comm::IoCallback::size

Definition at line 37 of file IoCallback.h.

Referenced by setCallback(), and Comm::Write().

◆ type

iocb_type Comm::IoCallback::type

Definition at line 32 of file IoCallback.h.

Referenced by Comm::CallbackTableInit(), and setCallback().

◆ xerrno

int Comm::IoCallback::xerrno

Definition at line 40 of file IoCallback.h.

Referenced by reset().

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






Web Site Translations