#include <WIN32_Asynch_IO.h>
Inheritance diagram for ACE_WIN32_Asynch_Write_Dgram_Result:


Public Member Functions | |
| size_t | bytes_to_write (void) const | 
| ACE_Message_Block * | message_block (void) const | 
| Message block which contains the sent data.   | |
| int | flags (void) const | 
| The flags using in the write.   | |
| ACE_HANDLE | handle (void) const | 
| I/O handle used for writing.   | |
| 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 | 
| u_long | error (void) const | 
| Error value if the operation fail.   | |
| ACE_HANDLE | event (void) const | 
| Event associated with the OVERLAPPED structure.   | |
| u_long | offset (void) const | 
| This really make sense only when doing file I/O.   | |
| u_long | offset_high (void) const | 
| Offset_high associated with the OVERLAPPED structure.   | |
| int | priority (void) const | 
| int | signal_number (void) const | 
| No-op. Returns 0.   | |
| int | post_completion (ACE_Proactor_Impl *proactor) | 
| Post  to the Proactor's completion port.   | |
Protected Member Functions | |
| ACE_WIN32_Asynch_Write_Dgram_Result (const ACE_Handler::Proxy_Ptr &handler_proxy, ACE_HANDLE handle, ACE_Message_Block *message_block, size_t bytes_to_write, int flags, const void *act, ACE_HANDLE event, int priority, int signal_number=0) | |
| virtual void | complete (size_t bytes_transferred, int success, const void *completion_key, u_long error) | 
| ACE_Proactor will call this method when the write completes.   | |
| virtual | ~ACE_WIN32_Asynch_Write_Dgram_Result (void) | 
| Destructor.   | |
Protected Attributes | |
| size_t | bytes_to_write_ | 
| ACE_Message_Block * | message_block_ | 
| Message block used for the send.   | |
| int | flags_ | 
| The flags using in the write.   | |
| ACE_HANDLE | handle_ | 
| I/O handle used for writing.   | |
Friends | |
| class | ACE_WIN32_Asynch_Write_Dgram | 
| Factory class willl have special permissions.   | |
| class | ACE_WIN32_Proactor | 
| Proactor class has special permission.   | |
Definition at line 1753 of file WIN32_Asynch_IO.h.
      
  | 
  ||||||||||||||||||||||||||||||||||||||||
| 
 Constructor is protected since creation is limited to ACE_Asynch_Write_Stream factory. Definition at line 3516 of file WIN32_Asynch_IO.cpp. References ACE_Handler::Proxy_Ptr. 
 03526 : ACE_Asynch_Result_Impl (), 03527 ACE_Asynch_Write_Dgram_Result_Impl(), 03528 ACE_WIN32_Asynch_Result (handler_proxy, 03529 act, 03530 event, 03531 0, 03532 0, 03533 priority, 03534 signal_number), 03535 bytes_to_write_ (bytes_to_write), 03536 message_block_ (message_block), 03537 flags_ (flags), 03538 handle_ (handle) 03539 { 03540 }  | 
  
      
  | 
  
| 
 Destructor. 
 Definition at line 3578 of file WIN32_Asynch_IO.cpp. 
 03579 {
03580 }
 | 
  
      
  | 
  
| 
 ACT associated with the operation. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3457 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::act(). 
 03458 {
03459   return ACE_WIN32_Asynch_Result::act ();
03460 }
 | 
  
      
  | 
  
| 
 The number of bytes which were requested at the start of the asynchronous write. Implements ACE_Asynch_Write_Dgram_Result_Impl. Definition at line 3427 of file WIN32_Asynch_IO.cpp. 
 03428 {
03429   return this->bytes_to_write_;
03430 }
 | 
  
      
  | 
  
| 
 Number of bytes transferred by the operation. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3451 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::bytes_transferred(). 
 03452 {
03453   return ACE_WIN32_Asynch_Result::bytes_transferred ();
03454 }
 | 
  
      
  | 
  ||||||||||||||||||||
| 
 ACE_Proactor will call this method when the write completes. 
 Implements ACE_Asynch_Result_Impl. Definition at line 3543 of file WIN32_Asynch_IO.cpp. References ACE_Message_Block::cont(), ACE_Refcounted_Auto_Ptr< X, ACE_LOCK >::get(), ACE_Handler::handle_write_dgram(), ACE_Message_Block::length(), and ACE_Message_Block::rd_ptr(). 
 03547 {
03548   // Copy the data which was returned by GetQueuedCompletionStatus
03549   this->bytes_transferred_ = bytes_transferred;
03550   this->success_ = success;
03551   this->completion_key_ = completion_key;
03552   this->error_ = error;
03553 
03554   // Appropriately move the pointers in the message block.
03555   for (ACE_Message_Block* mb = this->message_block_;
03556        (mb != 0) && (bytes_transferred > 0);
03557        mb = mb->cont ())
03558     {
03559       size_t len_part = mb->length ();
03560 
03561       if ( len_part > bytes_transferred)
03562         len_part = bytes_transferred;
03563 
03564       mb->rd_ptr (len_part);
03565 
03566       bytes_transferred -= len_part;
03567     }
03568 
03569   // Create the interface result class.
03570   ACE_Asynch_Write_Dgram::Result result (this);
03571 
03572   // Call the application handler.
03573   ACE_Handler *handler = this->handler_proxy_.get ()->handler ();
03574   if (handler != 0)
03575     handler->handle_write_dgram (result);
03576 }
 | 
  
      
  | 
  
| 
 This returns the ACT associated with the handle when it was registered with the I/O completion port. This ACT is not the same as the ACT associated with the asynchronous operation. Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3469 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::completion_key(). 
 03470 {
03471   return ACE_WIN32_Asynch_Result::completion_key ();
03472 }
 | 
  
      
  | 
  
| 
 Error value if the operation fail. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3475 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::error(). 
 03476 {
03477   return ACE_WIN32_Asynch_Result::error ();
03478 }
 | 
  
      
  | 
  
| 
 Event associated with the OVERLAPPED structure. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3481 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::event(). 
 03482 {
03483   return ACE_WIN32_Asynch_Result::event ();
03484 }
 | 
  
      
  | 
  
| 
 The flags using in the write. 
 Implements ACE_Asynch_Write_Dgram_Result_Impl. Definition at line 3439 of file WIN32_Asynch_IO.cpp. 
 03440 {
03441   return this->flags_;
03442 }
 | 
  
      
  | 
  
| 
 I/O handle used for writing. 
 Implements ACE_Asynch_Write_Dgram_Result_Impl. Definition at line 3445 of file WIN32_Asynch_IO.cpp. Referenced by ACE_WIN32_Asynch_Write_Dgram::send(). 
 03446 {
03447   return this->handle_;
03448 }
 | 
  
      
  | 
  
| 
 Message block which contains the sent data. 
 Implements ACE_Asynch_Write_Dgram_Result_Impl. Definition at line 3433 of file WIN32_Asynch_IO.cpp. 
 03434 {
03435   return this->message_block_;
03436 }
 | 
  
      
  | 
  
| 
 This really make sense only when doing file I/O. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3487 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::offset(). 
 03488 {
03489   return ACE_WIN32_Asynch_Result::offset ();
03490 }
 | 
  
      
  | 
  
| 
 Offset_high associated with the OVERLAPPED structure. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3493 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::offset_high(). 
 03494 {
03495   return ACE_WIN32_Asynch_Result::offset_high ();
03496 }
 | 
  
      
  | 
  
| 
 Post to the Proactor's completion port. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3511 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::post_completion(). 
 03512 {
03513   return ACE_WIN32_Asynch_Result::post_completion (proactor);
03514 }
 | 
  
      
  | 
  
| 
 The priority of the asynchronous operation. Currently, this is not supported on Win32. Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3499 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::priority(). 
 03500 {
03501   return ACE_WIN32_Asynch_Result::priority ();
03502 }
 | 
  
      
  | 
  
| 
 No-op. Returns 0. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3505 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::signal_number(). 
 03506 {
03507   return ACE_WIN32_Asynch_Result::signal_number ();
03508 }
 | 
  
      
  | 
  
| 
 Did the operation succeed? 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 3463 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::success(). 
 03464 {
03465   return ACE_WIN32_Asynch_Result::success ();
03466 }
 | 
  
      
  | 
  
| 
 Factory class willl have special permissions. 
 Definition at line 1757 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 Proactor class has special permission. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 1760 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 The number of bytes which were requested at the start of the asynchronous write. Definition at line 1841 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 The flags using in the write. 
 Definition at line 1847 of file WIN32_Asynch_IO.h. Referenced by ACE_WIN32_Asynch_Write_Dgram::send().  | 
  
      
  | 
  
| 
 I/O handle used for writing. 
 Definition at line 1850 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 Message block used for the send. 
 Definition at line 1844 of file WIN32_Asynch_IO.h.  | 
  
 
1.3.6