#include <POSIX_Asynch_IO.h>
Inheritance diagram for ACE_POSIX_Asynch_Accept_Result:


Public Member Functions | |
| size_t | bytes_to_read (void) const |
| ACE_Message_Block & | message_block (void) const |
| Message block which contains the read data. | |
| ACE_HANDLE | listen_handle (void) const |
| I/O handle used for accepting new connections. | |
| ACE_HANDLE | accept_handle (void) const |
| I/O handle for the new connection. | |
Protected Member Functions | |
| ACE_POSIX_Asynch_Accept_Result (const ACE_Handler::Proxy_Ptr &handler_proxy, ACE_HANDLE listen_handle, ACE_HANDLE accept_handle, ACE_Message_Block &message_block, size_t bytes_to_read, const void *act, ACE_HANDLE event, int priority, int signal_number) | |
| virtual void | complete (size_t bytes_transferred, int success, const void *completion_key, u_long error) |
| ACE_Proactor will call this method when the accept completes. | |
| virtual | ~ACE_POSIX_Asynch_Accept_Result (void) |
| Destructor. | |
Protected Attributes | |
| ACE_Message_Block & | message_block_ |
| Message block for reading the data into. | |
| ACE_HANDLE | listen_handle_ |
| I/O handle used for accepting new connections. | |
Friends | |
| class | ACE_POSIX_Asynch_Accept |
| Factory classes will have special permissions. | |
| class | ACE_POSIX_Proactor |
| The Proactor constructs the Result class for faking results. | |
This class has all the information necessary for the handler to uniquiely identify the completion of the asynchronous accept.
Definition at line 596 of file POSIX_Asynch_IO.h.
|
||||||||||||||||||||||||||||||||||||||||
|
Constructor is protected since creation is limited to ACE_Asynch_Accept factory. Definition at line 731 of file POSIX_Asynch_IO.cpp. References ACE_Handler::Proxy_Ptr.
00741 : ACE_POSIX_Asynch_Result 00742 (handler_proxy, act, event, 0, 0, priority, signal_number), 00743 message_block_ (message_block), 00744 listen_handle_ (listen_handle) 00745 { 00746 this->aio_fildes = accept_handle; 00747 this->aio_nbytes = bytes_to_read; 00748 } |
|
|
Destructor.
Definition at line 774 of file POSIX_Asynch_IO.cpp.
00775 {
00776 }
|
|
|
I/O handle for the new connection.
Implements ACE_Asynch_Accept_Result_Impl. Definition at line 725 of file POSIX_Asynch_IO.cpp.
00726 {
00727 return this->aio_fildes;
00728 }
|
|
|
The number of bytes which were requested at the start of the asynchronous accept. Implements ACE_Asynch_Accept_Result_Impl. Definition at line 707 of file POSIX_Asynch_IO.cpp.
00708 {
00709 return this->aio_nbytes;
00710 }
|
|
||||||||||||||||||||
|
ACE_Proactor will call this method when the accept completes.
Implements ACE_Asynch_Result_Impl. Definition at line 751 of file POSIX_Asynch_IO.cpp. References ACE_Refcounted_Auto_Ptr< X, ACE_LOCK >::get(), ACE_Handler::handle_accept(), and ACE_Message_Block::wr_ptr().
00755 {
00756 // Copy the data.
00757 this->bytes_transferred_ = bytes_transferred;
00758 this->success_ = success;
00759 this->completion_key_ = completion_key;
00760 this->error_ = error;
00761
00762 // Appropriately move the pointers in the message block.
00763 this->message_block_.wr_ptr (bytes_transferred);
00764
00765 // Create the interface result class.
00766 ACE_Asynch_Accept::Result result (this);
00767
00768 // Call the application handler.
00769 ACE_Handler *handler = this->handler_proxy_.get ()->handler ();
00770 if (handler != 0)
00771 handler->handle_accept (result);
00772 }
|
|
|
I/O handle used for accepting new connections.
Implements ACE_Asynch_Accept_Result_Impl. Definition at line 719 of file POSIX_Asynch_IO.cpp.
00720 {
00721 return this->listen_handle_;
00722 }
|
|
|
Message block which contains the read data.
Implements ACE_Asynch_Accept_Result_Impl. Definition at line 713 of file POSIX_Asynch_IO.cpp.
00714 {
00715 return this->message_block_;
00716 }
|
|
|
Factory classes will have special permissions.
Definition at line 600 of file POSIX_Asynch_IO.h. |
|
|
The Proactor constructs the Result class for faking results.
Definition at line 603 of file POSIX_Asynch_IO.h. |
|
|
I/O handle used for accepting new connections.
Definition at line 649 of file POSIX_Asynch_IO.h. |
|
|
Message block for reading the data into.
Definition at line 646 of file POSIX_Asynch_IO.h. |
1.3.6