ACE 8.0.1
|
This class is an example of the Connector pattern. This class will establish new connections and create new HANDLER objects to handle the new connections. More...
#include <Asynch_Connector.h>
Protected Member Functions | |
virtual void | handle_connect (const ACE_Asynch_Connect::Result &result) |
This is called when an outstanding accept completes. | |
void | parse_address (const ACE_Asynch_Connect::Result &result, ACE_INET_Addr &remote_address, ACE_INET_Addr &local_address) |
This parses the address from read buffer. | |
ACE_Asynch_Connect & | asynch_connect () |
Return the asynch Connect object. | |
virtual HANDLER * | make_handler () |
Private Attributes | |
ACE_Asynch_Connect | asynch_connect_ |
Asynch_Connect used to make life easier :-) | |
bool | pass_addresses_ |
Flag that indicates if parsing of addresses is necessary. | |
bool | validate_new_connection_ |
Flag that indicates if address validation is required. | |
Additional Inherited Members | |
![]() | |
typedef ACE_Refcounted_Auto_Ptr< Proxy, ACE_SYNCH_MUTEX > | Proxy_Ptr |
![]() | |
ACE_Proactor * | proactor_ |
The proactor associated with this handler. | |
ACE_HANDLE | handle_ |
The ACE_HANDLE in use with this handler. | |
ACE_Refcounted_Auto_Ptr< Proxy, ACE_SYNCH_MUTEX > | proxy_ |
Refers to proxy for this handler. | |
This class is an example of the Connector pattern. This class will establish new connections and create new HANDLER objects to handle the new connections.
Unlike the ACE_Connector, however, this class is designed to be used asynchronously with the ACE Proactor framework.
A do nothing constructor.
|
virtualdefault |
Virtual destruction.
|
protected |
Return the asynch Connect object.
|
virtual |
This cancels all pending accepts operations that were issued by the calling thread.
|
virtual |
This initiates a new asynchronous connect.
|
protectedvirtual |
This is called when an outstanding accept completes.
Reimplemented from ACE_Handler.
|
protectedvirtual |
This is the template method used to create new handler. Subclasses must overwrite this method if a new handler creation strategy is required.
|
virtual |
This opens asynch connector
|
protected |
This parses the address from read buffer.
|
virtual |
Set and get flag that indicates if parsing and passing of addresses to the service_handler is necessary.
|
virtual |
|
virtual |
Template method to validate peer before service is opened. This method is called when the connection attempt completes, whether it succeeded or failed, if the validate_connection argument to open()
was non-zero or the validate_new_connection()
method is called to turn this feature on. The default implementation returns 0. Users can (and probably should) reimplement this method to learn about the success or failure of the connection attempt. If the connection completed successfully, this method can be used to perform validation of the peer using it's address, running an authentication procedure (such as SSL) or anything else necessary or desireable. The return value from this method determines whether or not ACE will continue opening the service or abort the connection.
result | Result of the connection acceptance. Use result.success() to determine success or failure of the connection attempt. |
remote | Peer's address. If the connection failed, this object is undefined. |
local | Local address connection was completed from. If the connection failed, this object is undefined. |
-1 | ACE_Asynch_Connector will close the connection, and the service will not be opened. |
0 | Service opening will proceeed. |
|
virtual |
Set and get flag that indicates if address validation is required.
|
virtual |
|
private |
Asynch_Connect used to make life easier :-)
|
private |
Flag that indicates if parsing of addresses is necessary.
|
private |
Flag that indicates if address validation is required.