#include <Asynch_IO.h>
Inheritance diagram for ACE_Asynch_Result:
Public Member Functions | |
size_t | bytes_transferred (void) const |
Number of bytes transferred by the operation. | |
const void * | act (void) const |
ACT associated with the operation. | |
int | success (void) const |
Did the operation succeed? | |
const void * | completion_key (void) const |
unsigned long | error (void) const |
Error value if the operation fails. | |
ACE_HANDLE | event (void) const |
unsigned long | offset (void) const |
unsigned long | offset_high (void) const |
int | priority (void) const |
int | signal_number (void) const |
virtual | ~ACE_Asynch_Result (void) |
Destructor. | |
Protected Member Functions | |
ACE_Asynch_Result (ACE_Asynch_Result_Impl *implementation) | |
ACE_Asynch_Result_Impl * | implementation (void) const |
Get the implementation class. | |
Protected Attributes | |
ACE_Asynch_Result_Impl * | implementation_ |
Implementation class. |
An interface base class from which you can obtain some basic information like the number of bytes transferred, the ACT associated with the asynchronous operation, indication of success or failure, etc. Subclasses may want to store more information that is particular to the asynchronous operation it represents.
Definition at line 105 of file Asynch_IO.h.
|
Destructor.
Definition at line 82 of file Asynch_IO.cpp.
00083 {
00084 // Proactor deletes the implementation when the <complete> finishes.
00085 }
|
|
Constructor. This implementation will not be deleted. The implementation will be deleted by the Proactor. Definition at line 77 of file Asynch_IO.cpp.
00078 : implementation_ (implementation) 00079 { 00080 } |
|
ACT associated with the operation.
Definition at line 24 of file Asynch_IO.cpp. References ACE_Asynch_Result_Impl::act(), and implementation(). Referenced by ACE_Asynch_Acceptor< HANDLER >::handle_accept(), ACE_Asynch_Connector< HANDLER >::handle_connect(), and ACE_POSIX_Asynch_Transmit_Handler::handle_write_stream().
00025 { 00026 return this->implementation ()->act (); 00027 } |
|
Number of bytes transferred by the operation.
Definition at line 18 of file Asynch_IO.cpp. References ACE_Asynch_Result_Impl::bytes_transferred(), and implementation(). Referenced by ACE_POSIX_Asynch_Transmit_Handler::handle_read_file(), and ACE_POSIX_Asynch_Transmit_Handler::handle_write_stream().
00019 { 00020 return this->implementation ()->bytes_transferred (); 00021 } |
|
This is the ACT associated with the handle on which the Asynch_Operation takes place. On WIN32, this returns the ACT associated with the handle when it was registered with the I/O completion port. @ This is not implemented for POSIX4 platforms. Returns 0. Definition at line 36 of file Asynch_IO.cpp. References ACE_Asynch_Result_Impl::completion_key(), and implementation().
00037 { 00038 return this->implementation ()->completion_key (); 00039 } |
|
Error value if the operation fails.
Definition at line 42 of file Asynch_IO.cpp. References ACE_Asynch_Result_Impl::error(), and implementation(). Referenced by ACE_Asynch_Acceptor< HANDLER >::handle_accept(), and ACE_Asynch_Connector< HANDLER >::handle_connect().
00043 { 00044 return this->implementation ()->error (); 00045 } |
|
On WIN32, this returns the event associated with the OVERLAPPED structure. This returns ACE_INVALID_HANDLE on POSIX4-Unix platforms. Definition at line 48 of file Asynch_IO.cpp. References ACE_Asynch_Result_Impl::event(), and implementation().
00049 { 00050 return this->implementation ()->event (); 00051 } |
|
Get the implementation class.
Reimplemented in ACE_Asynch_Read_Stream::Result, ACE_Asynch_Write_Stream::Result, ACE_Asynch_Read_File::Result, ACE_Asynch_Write_File::Result, ACE_Asynch_Accept::Result, ACE_Asynch_Connect::Result, ACE_Asynch_Transmit_File::Result, ACE_Asynch_Read_Dgram::Result, and ACE_Asynch_Write_Dgram::Result. Definition at line 88 of file Asynch_IO.cpp. References implementation_. Referenced by act(), bytes_transferred(), completion_key(), error(), event(), offset(), offset_high(), priority(), signal_number(), and success().
00089 { 00090 return this->implementation_; 00091 } |
|
This really makes sense only when doing file I/O. On WIN32, these are represented in the OVERLAPPED datastructure. @ On POSIX4-Unix, offset_high should be supported using aiocb64. Definition at line 54 of file Asynch_IO.cpp. References implementation(), and ACE_Asynch_Result_Impl::offset().
00055 { 00056 return this->implementation ()->offset (); 00057 } |
|
Definition at line 60 of file Asynch_IO.cpp. References implementation(), and ACE_Asynch_Result_Impl::offset_high().
00061 { 00062 return this->implementation ()->offset_high (); 00063 } |
|
Priority of the operation. On POSIX4-Unix, this is supported. Priority works like {nice} in Unix. Negative values are not allowed. 0 means priority of the operation same as the process priority. 1 means priority of the operation is one less than process. And so forth. On Win32, this is a no-op. Definition at line 66 of file Asynch_IO.cpp. References implementation(), and ACE_Asynch_Result_Impl::priority().
00067 { 00068 return this->implementation ()->priority (); 00069 } |
|
POSIX4 real-time signal number to be used for the operation. {signal_number} ranges from ACE_SIGRTMIN to ACE_SIGRTMAX. By default, ACE_SIGRTMIN is used to issue {aio_} calls. This is a no-op on non-POSIX4 systems and returns 0. Definition at line 72 of file Asynch_IO.cpp. References implementation(), and ACE_Asynch_Result_Impl::signal_number().
00073 { 00074 return this->implementation ()->signal_number (); 00075 } |
|
Did the operation succeed?
Definition at line 30 of file Asynch_IO.cpp. References implementation(), and ACE_Asynch_Result_Impl::success(). Referenced by ACE_Asynch_Acceptor< HANDLER >::handle_accept(), ACE_Asynch_Connector< HANDLER >::handle_connect(), ACE_POSIX_Asynch_Transmit_Handler::handle_read_file(), and ACE_POSIX_Asynch_Transmit_Handler::handle_write_stream().
00031 { 00032 return this->implementation ()->success (); 00033 } |
|
Implementation class.
Reimplemented in ACE_Asynch_Read_Stream::Result, ACE_Asynch_Write_Stream::Result, ACE_Asynch_Read_File::Result, ACE_Asynch_Write_File::Result, ACE_Asynch_Accept::Result, ACE_Asynch_Connect::Result, ACE_Asynch_Transmit_File::Result, ACE_Asynch_Read_Dgram::Result, and ACE_Asynch_Write_Dgram::Result. Definition at line 184 of file Asynch_IO.h. Referenced by implementation(). |