Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages

# ACE_POSIX_Asynch_Transmit_Handler Class Reference

Auxillary handler for doing <Asynch_Transmit_File> in Unix. <ACE_POSIX_Asynch_Transmit_File> internally uses this. More...

Inheritance diagram for ACE_POSIX_Asynch_Transmit_Handler:

[legend]
Collaboration diagram for ACE_POSIX_Asynch_Transmit_Handler:

[legend]
List of all members.

## Public Methods
| ACE_POSIX_Asynch_Transmit_Handler (ACE_POSIX_Proactor *posix_proactor, ACE_POSIX_Asynch_Transmit_File_Result *result)
| Constructor. Result pointer will have all the information to do the file transmission (socket, file, application handler, bytes to write). More...
virtual | ~ACE_POSIX_Asynch_Transmit_Handler (void)
| Destructor. More...
int | transmit (void)
| Do the transmission. All the info to do the transmission is in the <result> member. More...
## Protected Types
enum | ACT { HEADER_ACT = 1, DATA_ACT = 2, TRAILER_ACT = 3 }
## Protected Methods
virtual void | handle_write_stream (const ACE_Asynch_Write_Stream::Result &result)
| This is called when asynchronous writes from the socket complete. More...
virtual void | handle_read_file (const ACE_Asynch_Read_File::Result &result)
| This is called when asynchronous reads from the file complete. More...
int | initiate_read_file (void)
| Issue asynch read from the file. More...
## Protected Attributes
ACE_POSIX_Asynch_Transmit_File_Result * | result_
| The asynch result pointer made from the initial transmit file request. More...
ACE_Message_Block * | mb_
| Message bloack used to do the transmission. More...
ACT | header_act_
| ACT to transmit header. More...
ACT | data_act_
| ACT to transmit data. More...
ACT | trailer_act_
| ACT to transmit trailer. More...
size_t | file_offset_
| Current offset of the file being transmitted. More...
size_t | file_size_
| Total size of the file. More...
size_t | bytes_transferred_
| Number of bytes transferred on the stream. More...
ACE_POSIX_Asynch_Read_File | rf_
| To read from the file to be transmitted. More...
ACE_POSIX_Asynch_Write_Stream | ws_
| Write stream to write the header, trailer and the data. More...

## Detailed Description

Auxillary handler for doing <Asynch_Transmit_File> in Unix. <ACE_POSIX_Asynch_Transmit_File> internally uses this.

This is a helper class for implementing <ACE_POSIX_Asynch_Transmit_File> in Unix systems.

## Member Enumeration Documentation

enum ACE_POSIX_Asynch_Transmit_Handler::ACT`[protected]`

  | Enumeration values:
  HEADER_ACT |
  DATA_ACT |
  TRAILER_ACT |

## Constructor & Destructor Documentation

ACE_POSIX_Asynch_Transmit_Handler::ACE_POSIX_Asynch_Transmit_Handler | ( | ACE_POSIX_Proactor * | posix_proactor,
|  | ACE_POSIX_Asynch_Transmit_File_Result * | result
| ) |

| Constructor. Result pointer will have all the information to do the file transmission (socket, file, application handler, bytes to write).

ACE_POSIX_Asynch_Transmit_Handler::~ACE_POSIX_Asynch_Transmit_Handler | ( | void |  | ) | `[virtual]`

| Destructor.

## Member Function Documentation

void ACE_POSIX_Asynch_Transmit_Handler::handle_read_file | ( | const ACE_Asynch_Read_File::Result & | result | ) | `[protected, virtual]`

| This is called when asynchronous reads from the file complete. Reimplemented from ACE_Handler.

void ACE_POSIX_Asynch_Transmit_Handler::handle_write_stream | ( | const ACE_Asynch_Write_Stream::Result & | result | ) | `[protected, virtual]`

| This is called when asynchronous writes from the socket complete. Reimplemented from ACE_Handler.

int ACE_POSIX_Asynch_Transmit_Handler::initiate_read_file | ( | void |  | ) | `[protected]`

| Issue asynch read from the file.

int ACE_POSIX_Asynch_Transmit_Handler::transmit | ( | void |  | ) |

| Do the transmission. All the info to do the transmission is in the <result> member.

## Member Data Documentation

size_t ACE_POSIX_Asynch_Transmit_Handler::bytes_transferred_`[protected]`

| Number of bytes transferred on the stream.

ACT ACE_POSIX_Asynch_Transmit_Handler::data_act_`[protected]`

| ACT to transmit data.

size_t ACE_POSIX_Asynch_Transmit_Handler::file_offset_`[protected]`

| Current offset of the file being transmitted.

size_t ACE_POSIX_Asynch_Transmit_Handler::file_size_`[protected]`

| Total size of the file.

ACT ACE_POSIX_Asynch_Transmit_Handler::header_act_`[protected]`

| ACT to transmit header.

ACE_Message_Block* ACE_POSIX_Asynch_Transmit_Handler::mb_`[protected]`

| Message bloack used to do the transmission.

ACE_POSIX_Asynch_Transmit_File_Result* ACE_POSIX_Asynch_Transmit_Handler::result_`[protected]`

| The asynch result pointer made from the initial transmit file request.

ACE_POSIX_Asynch_Read_File ACE_POSIX_Asynch_Transmit_Handler::rf_`[protected]`

| To read from the file to be transmitted.

ACT ACE_POSIX_Asynch_Transmit_Handler::trailer_act_`[protected]`

| ACT to transmit trailer.

ACE_POSIX_Asynch_Write_Stream ACE_POSIX_Asynch_Transmit_Handler::ws_`[protected]`

| Write stream to write the header, trailer and the data.

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

- POSIX_Asynch_IO.cpp