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


Public Member Functions | |
| ACE_HANDLE | socket (void) const | 
| Socket used for transmitting the file.   | |
| ACE_HANDLE | file (void) const | 
| File from which the data is read.   | |
| ACE_Asynch_Transmit_File::Header_And_Trailer * | header_and_trailer (void) const | 
| Header and trailer data associated with this transmit file.   | |
| size_t | bytes_to_write (void) const | 
| size_t | bytes_per_send (void) const | 
| u_long | flags (void) const | 
| Flags which were passed into transmit file.   | |
| 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_Transmit_File_Result (const ACE_Handler::Proxy_Ptr &handler_proxy, ACE_HANDLE socket, ACE_HANDLE file, ACE_Asynch_Transmit_File::Header_And_Trailer *header_and_trailer, size_t bytes_to_write, u_long offset, u_long offset_high, size_t bytes_per_send, u_long 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) | 
| Proactor will call this method when the write completes.   | |
| virtual | ~ACE_WIN32_Asynch_Transmit_File_Result (void) | 
| Destructor.   | |
Protected Attributes | |
| ACE_HANDLE | socket_ | 
| Network I/O handle.   | |
| ACE_HANDLE | file_ | 
| File I/O handle.   | |
| ACE_Asynch_Transmit_File::Header_And_Trailer * | header_and_trailer_ | 
| Header and trailer data associated with this transmit file.   | |
| size_t | bytes_to_write_ | 
| size_t | bytes_per_send_ | 
| u_long | flags_ | 
| Flags which were passed into transmit file.   | |
Friends | |
| class | ACE_WIN32_Asynch_Transmit_File | 
| Factory class will have special permission.   | |
| class | ACE_WIN32_Proactor | 
| Proactor class has special permission.   | |
This class has all the information necessary for the to uniquiely identify the completion of the asynchronous transmit file.
Definition at line 1358 of file WIN32_Asynch_IO.h.
      
  | 
  ||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 
 Constructor is protected since creation is limited to ACE_Asynch_Transmit_File factory. Definition at line 2793 of file WIN32_Asynch_IO.cpp. References ACE_Handler::Proxy_Ptr. 
 02807 : ACE_Asynch_Result_Impl (), 02808 ACE_Asynch_Transmit_File_Result_Impl (), 02809 ACE_WIN32_Asynch_Result (handler_proxy, 02810 act, 02811 event, 02812 offset, 02813 offset_high, 02814 priority, 02815 signal_number), 02816 socket_ (socket), 02817 file_ (file), 02818 header_and_trailer_ (header_and_trailer), 02819 bytes_to_write_ (bytes_to_write), 02820 bytes_per_send_ (bytes_per_send), 02821 flags_ (flags) 02822 { 02823 }  | 
  
      
  | 
  
| 
 Destructor. 
 Definition at line 2862 of file WIN32_Asynch_IO.cpp. 
 02863 {
02864 }
 | 
  
      
  | 
  
| 
 ACT associated with the operation. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2876 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::act(). 
 02877 {
02878   return ACE_WIN32_Asynch_Result::act ();
02879 }
 | 
  
      
  | 
  
| 
 Number of bytes per send requested at the start of the transmit file. Implements ACE_Asynch_Transmit_File_Result_Impl. Definition at line 2782 of file WIN32_Asynch_IO.cpp. 
 02783 {
02784   return this->bytes_per_send_;
02785 }
 | 
  
      
  | 
  
| 
 The number of bytes which were requested at the start of the asynchronous transmit file. Implements ACE_Asynch_Transmit_File_Result_Impl. Definition at line 2776 of file WIN32_Asynch_IO.cpp. 
 02777 {
02778   return this->bytes_to_write_;
02779 }
 | 
  
      
  | 
  
| 
 Number of bytes transferred by the operation. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2870 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::bytes_transferred(). 
 02871 {
02872   return ACE_WIN32_Asynch_Result::bytes_transferred ();
02873 }
 | 
  
      
  | 
  ||||||||||||||||||||
| 
 Proactor will call this method when the write completes. 
 Implements ACE_Asynch_Result_Impl. Definition at line 2826 of file WIN32_Asynch_IO.cpp. References ACE_Refcounted_Auto_Ptr< X, ACE_LOCK >::get(), and ACE_Handler::handle_transmit_file(). 
 02830 {
02831   // Copy the data which was returned by GetQueuedCompletionStatus
02832   this->bytes_transferred_ = bytes_transferred;
02833   this->success_ = success;
02834   this->completion_key_ = completion_key;
02835   this->error_ = error;
02836 
02837   // We will not do this because (a) the header and trailer blocks may
02838   // be the same message_blocks and (b) in cases of failures we have
02839   // no idea how much of what (header, data, trailer) was sent.
02840   /*
02841     if (this->success_ && this->header_and_trailer_ != 0)
02842     {
02843     ACE_Message_Block *header = this->header_and_trailer_->header ();
02844     if (header != 0)
02845     header->rd_ptr (this->header_and_trailer_->header_bytes ());
02846 
02847     ACE_Message_Block *trailer = this->header_and_trailer_->trailer ();
02848     if (trailer != 0)
02849     trailer->rd_ptr (this->header_and_trailer_->trailer_bytes ());
02850     }
02851   */
02852 
02853   // Create the interface result class.
02854   ACE_Asynch_Transmit_File::Result result (this);
02855 
02856   // Call the application handler.
02857   ACE_Handler *handler = this->handler_proxy_.get ()->handler ();
02858   if (handler != 0)
02859     handler->handle_transmit_file (result);
02860 }
 | 
  
      
  | 
  
| 
 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 2888 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::completion_key(). 
 02889 {
02890   return ACE_WIN32_Asynch_Result::completion_key ();
02891 }
 | 
  
      
  | 
  
| 
 Error value if the operation fail. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2894 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::error(). 
 02895 {
02896   return ACE_WIN32_Asynch_Result::error ();
02897 }
 | 
  
      
  | 
  
| 
 Event associated with the OVERLAPPED structure. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2900 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::event(). 
 02901 {
02902   return ACE_WIN32_Asynch_Result::event ();
02903 }
 | 
  
      
  | 
  
| 
 File from which the data is read. 
 Implements ACE_Asynch_Transmit_File_Result_Impl. Definition at line 2764 of file WIN32_Asynch_IO.cpp. Referenced by ACE_WIN32_Asynch_Transmit_File::transmit_file(). 
 02765 {
02766   return this->file_;
02767 }
 | 
  
      
  | 
  
| 
 Flags which were passed into transmit file. 
 Implements ACE_Asynch_Transmit_File_Result_Impl. Definition at line 2788 of file WIN32_Asynch_IO.cpp. Referenced by ACE_WIN32_Asynch_Transmit_File::transmit_file(). 
 02789 {
02790   return this->flags_;
02791 }
 | 
  
      
  | 
  
| 
 Header and trailer data associated with this transmit file. 
 Implements ACE_Asynch_Transmit_File_Result_Impl. Definition at line 2770 of file WIN32_Asynch_IO.cpp. Referenced by ACE_WIN32_Asynch_Transmit_File::transmit_file(). 
 02771 {
02772   return this->header_and_trailer_;
02773 }
 | 
  
      
  | 
  
| 
 This really make sense only when doing file I/O. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2906 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::offset(). 
 02907 {
02908   return ACE_WIN32_Asynch_Result::offset ();
02909 }
 | 
  
      
  | 
  
| 
 Offset_high associated with the OVERLAPPED structure. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2912 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::offset_high(). 
 02913 {
02914   return ACE_WIN32_Asynch_Result::offset_high ();
02915 }
 | 
  
      
  | 
  
| 
 Post to the Proactor's completion port. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2930 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::post_completion(). 
 02931 {
02932   return ACE_WIN32_Asynch_Result::post_completion (proactor);
02933 }
 | 
  
      
  | 
  
| 
 The priority of the asynchronous operation. Currently, this is not supported on Win32. Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2918 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::priority(). 
 02919 {
02920   return ACE_WIN32_Asynch_Result::priority ();
02921 }
 | 
  
      
  | 
  
| 
 No-op. Returns 0. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2924 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::signal_number(). 
 02925 {
02926   return ACE_WIN32_Asynch_Result::signal_number ();
02927 }
 | 
  
      
  | 
  
| 
 Socket used for transmitting the file. 
 Implements ACE_Asynch_Transmit_File_Result_Impl. Definition at line 2758 of file WIN32_Asynch_IO.cpp. Referenced by ACE_WIN32_Asynch_Transmit_File::transmit_file(). 
 02759 {
02760   return this->socket_;
02761 }
 | 
  
      
  | 
  
| 
 Did the operation succeed? 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 2882 of file WIN32_Asynch_IO.cpp. References ACE_WIN32_Asynch_Result::success(). 
 02883 {
02884   return ACE_WIN32_Asynch_Result::success ();
02885 }
 | 
  
      
  | 
  
| 
 Factory class will have special permission. 
 Definition at line 1362 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 Proactor class has special permission. 
 Reimplemented from ACE_WIN32_Asynch_Result. Definition at line 1365 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 Number of bytes per send requested at the start of the transmit file. Definition at line 1470 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 The number of bytes which were requested at the start of the asynchronous transmit file. Definition at line 1466 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 File I/O handle. 
 Definition at line 1459 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 Flags which were passed into transmit file. 
 Definition at line 1473 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 Header and trailer data associated with this transmit file. 
 Definition at line 1462 of file WIN32_Asynch_IO.h.  | 
  
      
  | 
  
| 
 Network I/O handle. 
 Definition at line 1456 of file WIN32_Asynch_IO.h.  | 
  
 
1.3.6