File: ACE_Asynch_Operation.3

package info (click to toggle)
ace 5.2.1-1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 26,856 kB
  • ctags: 18,677
  • sloc: cpp: 171,831; makefile: 48,840; sh: 10,192; perl: 8,582; exp: 787; yacc: 387; lex: 140; csh: 20
file content (129 lines) | stat: -rw-r--r-- 5,368 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
.TH ACE_Asynch_Operation 3 "1 Dec 2001" "ACE" \" -*- nroff -*-
.ad l
.nh
.SH NAME
ACE_Asynch_Operation \- This is an interface base class for all asynch operations. The resposiblility of this class is to forward all methods to its delegation/implementation class, e.g.,  or . 
.SH SYNOPSIS
.br
.PP
\fC#include <Asynch_IO.h>\fR
.PP
Inherited by \fBACE_Asynch_Accept\fR, \fBACE_Asynch_Read_Dgram\fR, \fBACE_Asynch_Read_Stream\fR, \fBACE_Asynch_Transmit_File\fR, \fBACE_Asynch_Write_Dgram\fR, and \fBACE_Asynch_Write_Stream\fR.
.PP
.SS Public Methods

.in +1c
.ti -1c
.RI "int \fBopen\fR (\fBACE_Handler\fR &handler, ACE_HANDLE handle, const void *completion_key, \fBACE_Proactor\fR *proactor)"
.br
.ti -1c
.RI "int \fBcancel\fR (void)"
.br
.ti -1c
.RI "\fBACE_Proactor\fR* \fBproactor\fR (void) const"
.br
.RI "\fIReturn the underlying proactor.\fR"
.ti -1c
.RI "virtual \fB~ACE_Asynch_Operation\fR (void)"
.br
.RI "\fIDestructor.\fR"
.in -1c
.SS Protected Methods

.in +1c
.ti -1c
.RI "\fBACE_Asynch_Operation\fR (void)"
.br
.RI "\fIConstructor.\fR"
.ti -1c
.RI "\fBACE_Asynch_Operation_Impl\fR* \fBimplementation\fR (void) const"
.br
.RI "\fIReturn the underlying implementation class.\fR"
.ti -1c
.RI "void \fBimplementation\fR (\fBACE_Asynch_Operation_Impl\fR *implementation)"
.br
.RI "\fISet the implementation class.\fR"
.ti -1c
.RI "\fBACE_Proactor\fR* \fBget_proactor\fR (\fBACE_Proactor\fR *user_proactor, \fBACE_Handler\fR &handler) const"
.br
.RI "\fIGet a proactor for/from the user.\fR"
.in -1c
.SS Protected Attributes

.in +1c
.ti -1c
.RI "\fBACE_Asynch_Operation_Impl\fR* \fBimplementation_\fR"
.br
.RI "\fIImplementation class.\fR"
.in -1c
.SH DETAILED DESCRIPTION
.PP 
This is an interface base class for all asynch operations. The resposiblility of this class is to forward all methods to its delegation/implementation class, e.g.,  or .
.PP
.PP
 There are some attributes and functionality which is common to all asychronous operations. The delegation classes of this class will factor out this code. 
.PP
.SH CONSTRUCTOR & DESTRUCTOR DOCUMENTATION
.PP 
.SS ACE_Asynch_Operation::~ACE_Asynch_Operation (void)\fC [virtual]\fR
.PP
Destructor.
.PP
.SS ACE_Asynch_Operation::ACE_Asynch_Operation (void)\fC [protected]\fR
.PP
Constructor.
.PP
.SH MEMBER FUNCTION DOCUMENTATION
.PP 
.SS int ACE_Asynch_Operation::cancel (void)
.PP
(Attempts to) cancel the asynchronous operation pending against the <handle> registered with this Operation.
.PP
All completion notifications for the I/O operations will occur normally.
.PP
= Return Values:
.PP
-1 : Operation failed. (can get only in POSIX). 0 : All the operations were cancelled. 1 : All the operations were already finished in this handle. Unable to cancel them. 2 : Atleast one of the requested operations cannot be cancelled.
.PP
There is slight difference in the semantics between NT and POSIX platforms which is given below.
.PP
= Win32 :
.PP
cancels all pending accepts operations that were issued by the calling thread. The function does not cancel asynchronous operations issued by other threads. All I/O operations that are canceled will complete with the error ERROR_OPERATION_ABORTED.
.PP
= POSIX:
.PP
Attempts to cancel one or more asynchronous I/O requests currently outstanding against the <handle> registered in this operation. For requested operations that are successfully canceled, the associated error status is set to ECANCELED. 
.SS \fBACE_Proactor\fR * ACE_Asynch_Operation::get_proactor (\fBACE_Proactor\fR * user_proactor, \fBACE_Handler\fR & handler) const\fC [protected]\fR
.PP
Get a proactor for/from the user.
.PP
.SS void ACE_Asynch_Operation::implementation (\fBACE_Asynch_Operation_Impl\fR * implementation)\fC [protected]\fR
.PP
Set the implementation class.
.PP
.SS \fBACE_Asynch_Operation_Impl\fR * ACE_Asynch_Operation::implementation (void) const\fC [protected]\fR
.PP
Return the underlying implementation class.
.PP
Reimplemented in \fBACE_Asynch_Read_Stream\fR, \fBACE_Asynch_Write_Stream\fR, \fBACE_Asynch_Read_File\fR, \fBACE_Asynch_Write_File\fR, \fBACE_Asynch_Accept\fR, \fBACE_Asynch_Transmit_File\fR, \fBACE_Asynch_Read_Dgram\fR, and \fBACE_Asynch_Write_Dgram\fR.
.SS int ACE_Asynch_Operation::open (\fBACE_Handler\fR & handler, ACE_HANDLE handle, const void * completion_key, \fBACE_Proactor\fR * proactor)
.PP
Initializes the factory with information which will be used with each asynchronous call. If (<handle> == ACE_INVALID_HANDLE),  will be called on the <handler> to get the correct handle. 
.PP
Reimplemented in \fBACE_Asynch_Read_Stream\fR, \fBACE_Asynch_Write_Stream\fR, \fBACE_Asynch_Read_File\fR, \fBACE_Asynch_Write_File\fR, \fBACE_Asynch_Accept\fR, \fBACE_Asynch_Transmit_File\fR, \fBACE_Asynch_Read_Dgram\fR, and \fBACE_Asynch_Write_Dgram\fR.
.SS \fBACE_Proactor\fR * ACE_Asynch_Operation::proactor (void) const
.PP
Return the underlying proactor.
.PP
.SH MEMBER DATA DOCUMENTATION
.PP 
.SS \fBACE_Asynch_Operation_Impl\fR * ACE_Asynch_Operation::implementation_\fC [protected]\fR
.PP
Implementation class.
.PP
Reimplemented in \fBACE_Asynch_Read_Stream\fR, \fBACE_Asynch_Write_Stream\fR, \fBACE_Asynch_Read_File\fR, \fBACE_Asynch_Write_File\fR, \fBACE_Asynch_Accept\fR, \fBACE_Asynch_Transmit_File\fR, \fBACE_Asynch_Read_Dgram\fR, and \fBACE_Asynch_Write_Dgram\fR.

.SH AUTHOR
.PP 
Generated automatically by Doxygen for ACE from the source code.