ACE  6.1.8
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ACE_Handler Class Reference

This base class defines the interface for receiving the results of asynchronous operations. More...

#include <Asynch_IO.h>

Inheritance diagram for ACE_Handler:
Inheritance graph
[legend]
Collaboration diagram for ACE_Handler:
Collaboration graph
[legend]

Classes

class  Proxy
 The Proxy class acts as a proxy for dispatch of completions to operations issued for the associated handler. It allows the handler to be deleted while operations are outstanding. The proxy must be used to get the ACE_Handler pointer for dispatching, and if it's 0, the handler is no longer valid and the result should not be dispatched. More...
 

Public Types

typedef
ACE_Refcounted_Auto_Ptr< Proxy,
ACE_SYNCH_MUTEX
Proxy_Ptr
 

Public Member Functions

 ACE_Handler (void)
 A do nothing constructor. More...
 
 ACE_Handler (ACE_Proactor *p)
 A do nothing constructor which allows proactor to be set to <p>. More...
 
virtual ~ACE_Handler (void)
 Virtual destruction. More...
 
virtual void handle_read_stream (const ACE_Asynch_Read_Stream::Result &result)
 
virtual void handle_write_dgram (const ACE_Asynch_Write_Dgram::Result &result)
 
virtual void handle_read_dgram (const ACE_Asynch_Read_Dgram::Result &result)
 
virtual void handle_write_stream (const ACE_Asynch_Write_Stream::Result &result)
 
virtual void handle_read_file (const ACE_Asynch_Read_File::Result &result)
 
virtual void handle_write_file (const ACE_Asynch_Write_File::Result &result)
 
virtual void handle_accept (const ACE_Asynch_Accept::Result &result)
 This method will be called when an asynchronous accept completes. More...
 
virtual void handle_connect (const ACE_Asynch_Connect::Result &result)
 This method will be called when an asynchronous connect completes. More...
 
virtual void handle_transmit_file (const ACE_Asynch_Transmit_File::Result &result)
 
virtual void handle_time_out (const ACE_Time_Value &tv, const void *act=0)
 
virtual void handle_wakeup (void)
 
ACE_Proactorproactor (void)
 Get the proactor associated with this handler. More...
 
void proactor (ACE_Proactor *p)
 Set the proactor. More...
 
virtual ACE_HANDLE handle (void) const
 
virtual void handle (ACE_HANDLE)
 Set the ACE_HANDLE value for this Handler. More...
 
Proxy_Ptrproxy (void)
 

Protected Member Functions

 ACE_Handler (const ACE_Handler &)
 
ACE_Handler operator= (const ACE_Handler &)
 

Protected Attributes

ACE_Proactorproactor_
 The proactor associated with this handler. More...
 
ACE_HANDLE handle_
 The ACE_HANDLE in use with this handler. More...
 
ACE_Refcounted_Auto_Ptr< Proxy,
ACE_SYNCH_MUTEX
proxy_
 Refers to proxy for this handler. More...
 

Detailed Description

This base class defines the interface for receiving the results of asynchronous operations.

Subclasses of this class will fill in appropriate methods.

Member Typedef Documentation

Constructor & Destructor Documentation

ACE_Handler::ACE_Handler ( void  )

A do nothing constructor.

ACE_Handler::ACE_Handler ( ACE_Proactor p)

A do nothing constructor which allows proactor to be set to <p>.

ACE_Handler::~ACE_Handler ( void  )
virtual

Virtual destruction.

ACE_Handler::ACE_Handler ( const ACE_Handler )
protected

Member Function Documentation

ACE_HANDLE ACE_Handler::handle ( void  ) const
virtual

Get the I/O handle used by this {handler}. This method will be called by the ACE_Asynch_* classes when an ACE_INVALID_HANDLE is passed to {open}.

Reimplemented in ACE_Asynch_Acceptor< HANDLER >.

void ACE_Handler::handle ( ACE_HANDLE  h)
virtual

Set the ACE_HANDLE value for this Handler.

Reimplemented in ACE_Asynch_Acceptor< HANDLER >.

void ACE_Handler::handle_accept ( const ACE_Asynch_Accept::Result result)
virtual

This method will be called when an asynchronous accept completes.

Reimplemented in ACE_Asynch_Acceptor< HANDLER >.

void ACE_Handler::handle_connect ( const ACE_Asynch_Connect::Result result)
virtual

This method will be called when an asynchronous connect completes.

Reimplemented in ACE_Asynch_Connector< HANDLER >.

void ACE_Handler::handle_read_dgram ( const ACE_Asynch_Read_Dgram::Result result)
virtual

This method will be called when an asynchronous read completes on a UDP socket.

void ACE_Handler::handle_read_file ( const ACE_Asynch_Read_File::Result result)
virtual

This method will be called when an asynchronous read completes on a file.

Reimplemented in ACE_POSIX_Asynch_Transmit_Handler.

void ACE_Handler::handle_read_stream ( const ACE_Asynch_Read_Stream::Result result)
virtual

This method will be called when an asynchronous read completes on a stream.

Reimplemented in ACE_AIOCB_Notify_Pipe_Manager.

void ACE_Handler::handle_time_out ( const ACE_Time_Value tv,
const void *  act = 0 
)
virtual

Called when timer expires. {tv} was the requested time value and {act} is the ACT passed when scheduling the timer.

void ACE_Handler::handle_transmit_file ( const ACE_Asynch_Transmit_File::Result result)
virtual

This method will be called when an asynchronous transmit file completes.

void ACE_Handler::handle_wakeup ( void  )
virtual

This is method works with the {run_event_loop} of the ACE_Proactor. A special {Wake_Up_Completion} is used to wake up all the threads that are blocking for completions.

void ACE_Handler::handle_write_dgram ( const ACE_Asynch_Write_Dgram::Result result)
virtual

This method will be called when an asynchronous write completes on a UDP socket.

void ACE_Handler::handle_write_file ( const ACE_Asynch_Write_File::Result result)
virtual

This method will be called when an asynchronous write completes on a file.

void ACE_Handler::handle_write_stream ( const ACE_Asynch_Write_Stream::Result result)
virtual

This method will be called when an asynchronous write completes on a stream.

Reimplemented in ACE_POSIX_Asynch_Transmit_Handler.

ACE_Handler ACE_Handler::operator= ( const ACE_Handler )
protected
ACE_Proactor * ACE_Handler::proactor ( void  )

Get the proactor associated with this handler.

void ACE_Handler::proactor ( ACE_Proactor p)

Set the proactor.

ACE_Refcounted_Auto_Ptr< ACE_Handler::Proxy, ACE_SYNCH_MUTEX > & ACE_Handler::proxy ( void  )

Member Data Documentation

ACE_HANDLE ACE_Handler::handle_
protected

The ACE_HANDLE in use with this handler.

ACE_Proactor* ACE_Handler::proactor_
protected

The proactor associated with this handler.

ACE_Refcounted_Auto_Ptr<Proxy, ACE_SYNCH_MUTEX> ACE_Handler::proxy_
protected

Refers to proxy for this handler.


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