File: ACE_FlReactor.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 (180 lines) | stat: -rw-r--r-- 7,611 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
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
.TH ACE_FlReactor 3 "1 Dec 2001" "ACE" \" -*- nroff -*-
.ad l
.nh
.SH NAME
ACE_FlReactor \- A Reactor implementation that uses the Fast-Light (FL) toolkit for event demultiplexing. This will let us integrate the FL toolkit with \fBACE\fR and/or TAO. 
.SH SYNOPSIS
.br
.PP
\fC#include <FlReactor.h>\fR
.PP
Inherits \fBACE_Select_Reactor_T\fR.
.PP
.SS Public Methods

.in +1c
.ti -1c
.RI "\fBACE_FlReactor\fR (size_t size = DEFAULT_SIZE, int restart = 0, \fBACE_Sig_Handler\fR * = 0)"
.br
.ti -1c
.RI "virtual \fB~ACE_FlReactor\fR (void)"
.br
.ti -1c
.RI "virtual long \fBschedule_timer\fR (\fBACE_Event_Handler\fR *handler, const void *arg, const \fBACE_Time_Value\fR &delay_time, const \fBACE_Time_Value\fR &interval)"
.br
.ti -1c
.RI "virtual int \fBreset_timer_interval\fR (long timer_id, const \fBACE_Time_Value\fR &interval)"
.br
.ti -1c
.RI "virtual int \fBcancel_timer\fR (\fBACE_Event_Handler\fR *handler, int dont_call_handle_close = 1)"
.br
.ti -1c
.RI "virtual int \fBcancel_timer\fR (long timer_id, const void **arg = 0, int dont_call_handle_close = 1)"
.br
.in -1c
.SS Protected Methods

.in +1c
.ti -1c
.RI "virtual int \fBregister_handler_i\fR (ACE_HANDLE handle, \fBACE_Event_Handler\fR *handler, \fBACE_Reactor_Mask\fR mask)"
.br
.RI "\fIRegister a single <handler>.\fR"
.ti -1c
.RI "virtual int \fBregister_handler_i\fR (const \fBACE_Handle_Set\fR &handles, \fBACE_Event_Handler\fR *handler, \fBACE_Reactor_Mask\fR mask)"
.br
.RI "\fIRegister a set of <handlers>.\fR"
.ti -1c
.RI "virtual int \fBremove_handler_i\fR (ACE_HANDLE handle, \fBACE_Reactor_Mask\fR mask)"
.br
.RI "\fIRemove the <handler> associated with this <handle>.\fR"
.ti -1c
.RI "virtual int \fBremove_handler_i\fR (const \fBACE_Handle_Set\fR &handles, \fBACE_Reactor_Mask\fR)"
.br
.RI "\fIRemove a set of <handles>.\fR"
.ti -1c
.RI "virtual int \fBwait_for_multiple_events\fR (\fBACE_Select_Reactor_Handle_Set\fR &, \fBACE_Time_Value\fR *)"
.br
.RI "\fIWait for events to occur.\fR"
.in -1c
.SS Private Methods

.in +1c
.ti -1c
.RI "void \fBreset_timeout\fR (void)"
.br
.RI "\fIThis method ensures there's an Fl timeout for the first timeout in the Reactor's Timer_Queue.\fR"
.ti -1c
.RI "\fBACE_FlReactor\fR (const ACE_FlReactor &)"
.br
.RI "\fIDeny access since member-wise won't work...\fR"
.ti -1c
.RI "ACE_FlReactor& \fBoperator=\fR (const ACE_FlReactor &)"
.br
.in -1c
.SS Static Private Methods

.in +1c
.ti -1c
.RI "void \fBfl_io_proc\fR (int fd, void*)"
.br
.ti -1c
.RI "void \fBfl_timeout_proc\fR (void*)"
.br
.in -1c
.SH DETAILED DESCRIPTION
.PP 
A Reactor implementation that uses the Fast-Light (FL) toolkit for event demultiplexing. This will let us integrate the FL toolkit with \fBACE\fR and/or TAO.
.PP
.PP
 As many other GUI toolkits FL supports a minimal set of callbacks to handle event demultiplexing, namely simple methods to add file descriptors to the event demuxing set or timeout events. This class adapts this simple mechanisms so they are compatible with \fBACE\fR's Reactor. 
.PP
.SH CONSTRUCTOR & DESTRUCTOR DOCUMENTATION
.PP 
.SS ACE_FlReactor::ACE_FlReactor (size_t size = DEFAULT_SIZE, int restart = 0, \fBACE_Sig_Handler\fR * = 0)
.PP
.SS virtual ACE_FlReactor::~ACE_FlReactor (void)\fC [virtual]\fR
.PP
.SS ACE_FlReactor::ACE_FlReactor (const ACE_FlReactor &)\fC [private]\fR
.PP
Deny access since member-wise won't work...
.PP
.SH MEMBER FUNCTION DOCUMENTATION
.PP 
.SS virtual int ACE_FlReactor::cancel_timer (long timer_id, const void ** arg = 0, int dont_call_handle_close = 1)\fC [virtual]\fR
.PP
Cancel the single  that matches the <timer_id> value (which was returned from the <schedule> method). If arg is non-NULL then it will be set to point to the ``magic cookie'' argument passed in when the <Event_Handler> was registered. This makes it possible to free up the memory and avoid memory leaks. If <dont_call_handle_close> is 0 then the <handle_close> method of <event_handler> will be invoked. Returns 1 if cancellation succeeded and 0 if the <timer_id> wasn't found. 
.PP
Reimplemented from \fBACE_Select_Reactor_T\fR.
.SS virtual int ACE_FlReactor::cancel_timer (\fBACE_Event_Handler\fR * handler, int dont_call_handle_close = 1)\fC [virtual]\fR
.PP
Cancel all <event_handlers> that match the address of <event_handler>. If <dont_call_handle_close> is 0 then the <handle_close> method of <event_handler> will be invoked. Returns number of handler's cancelled. 
.PP
Reimplemented from \fBACE_Select_Reactor_T\fR.
.SS void ACE_FlReactor::fl_io_proc (int fd, void *)\fC [static, private]\fR
.PP
.SS void ACE_FlReactor::fl_timeout_proc (void *)\fC [static, private]\fR
.PP
.SS ACE_FlReactor& ACE_FlReactor::operator= (const ACE_FlReactor &)\fC [private]\fR
.PP
.SS int ACE_FlReactor::register_handler_i (const \fBACE_Handle_Set\fR & handles, \fBACE_Event_Handler\fR * handler, \fBACE_Reactor_Mask\fR mask)\fC [protected, virtual]\fR
.PP
Register a set of <handlers>.
.PP
Reimplemented from \fBACE_Select_Reactor_T\fR.
.SS int ACE_FlReactor::register_handler_i (ACE_HANDLE handle, \fBACE_Event_Handler\fR * handler, \fBACE_Reactor_Mask\fR mask)\fC [protected, virtual]\fR
.PP
Register a single <handler>.
.PP
Reimplemented from \fBACE_Select_Reactor_T\fR.
.SS int ACE_FlReactor::remove_handler_i (const \fBACE_Handle_Set\fR & handles, \fBACE_Reactor_Mask\fR mask)\fC [protected, virtual]\fR
.PP
Remove a set of <handles>.
.PP
Reimplemented from \fBACE_Select_Reactor_T\fR.
.SS int ACE_FlReactor::remove_handler_i (ACE_HANDLE handle, \fBACE_Reactor_Mask\fR mask)\fC [protected, virtual]\fR
.PP
Remove the <handler> associated with this <handle>.
.PP
Reimplemented from \fBACE_Select_Reactor_T\fR.
.SS void ACE_FlReactor::reset_timeout (void)\fC [private]\fR
.PP
This method ensures there's an Fl timeout for the first timeout in the Reactor's Timer_Queue.
.PP
.SS virtual int ACE_FlReactor::reset_timer_interval (long timer_id, const \fBACE_Time_Value\fR & interval)\fC [virtual]\fR
.PP
Resets the interval of the timer represented by <timer_id> to <interval>, which is specified in relative time to the current <gettimeofday>. If <interval> is equal to , the timer will become a non-rescheduling timer. Returns 0 if successful, -1 if not. 
.PP
Reimplemented from \fBACE_Select_Reactor_T\fR.
.SS virtual long ACE_FlReactor::schedule_timer (\fBACE_Event_Handler\fR * handler, const void * arg, const \fBACE_Time_Value\fR & delay_time, const \fBACE_Time_Value\fR & interval)\fC [virtual]\fR
.PP
Schedule an \fBACE_Event_Handler\fR that will expire after an amount of time. The return value of this method, a timer_id value, uniquely identifies the event_handler in the \fBACE_Reactor\fR's internal list of timers. This timer_id value can be used to cancel the timer with the \fBcancel_timer\fR() call.
.PP
\fBSee also: \fR
.in +1c
 \fBcancel_timer\fR() ,  \fBreset_timer_interval\fR()
.PP
\fBParameters: \fR
.in +1c
.TP
\fB\fIevent_handler\fR\fR event handler to schedule on reactor 
.TP
\fB\fIarg\fR\fR argument passed to the handle_timeout() method of event_handler 
.TP
\fB\fIdelta\fR\fR time interval after which the timer will expire 
.TP
\fB\fIinterval\fR\fR time interval after which the timer will be automatically rescheduled 
.PP
\fBReturns: \fR
.in +1c
 -1 on failure, a timer_id value on success 
.PP
Reimplemented from \fBACE_Select_Reactor_T\fR.
.SS int ACE_FlReactor::wait_for_multiple_events (\fBACE_Select_Reactor_Handle_Set\fR & handle_set, \fBACE_Time_Value\fR * max_wait_time)\fC [protected, virtual]\fR
.PP
Wait for events to occur.
.PP
Reimplemented from \fBACE_Select_Reactor_T\fR.

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