class_8h.html
31.9 KB
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
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>server: include/class.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript">
$(document).ready(initResizable);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body onload='searchBox.OnSelectItem(0);'>
<!-- Generated by Doxygen 1.7.3 -->
<script type="text/javascript"><!--
var searchBox = new SearchBox("searchBox", "search",false,'Search');
--></script>
<div id="top">
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td style="padding-left: 0.5em;">
<div id="projectname">server <span id="projectnumber">0.0.1</span></div>
<div id="projectbrief">basicserverinfrastructure</div>
</td>
</tr>
</tbody>
</table>
</div>
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main Page</span></a></li>
<li><a href="annotated.html"><span>Data Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
<li id="searchli">
<div id="MSearchBox" class="MSearchBoxInactive">
<span class="left">
<img id="MSearchSelect" src="search/mag_sel.png"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
alt=""/>
<input type="text" id="MSearchField" value="Search" accesskey="S"
onfocus="searchBox.OnSearchFieldFocus(true)"
onblur="searchBox.OnSearchFieldFocus(false)"
onkeyup="searchBox.OnSearchFieldChange(event)"/>
</span><span class="right">
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
</span>
</div>
</li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="files.html"><span>File List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul>
</div>
</div>
<div id="side-nav" class="ui-resizable side-nav-resizable">
<div id="nav-tree">
<div id="nav-tree-contents">
</div>
</div>
<div id="splitbar" style="-moz-user-select:none;"
class="ui-resizable-handle">
</div>
</div>
<script type="text/javascript">
initNavTree('class_8h.html','');
</script>
<div id="doc-content">
<div class="header">
<div class="summary">
<a href="#nested-classes">Data Structures</a> |
<a href="#define-members">Defines</a> |
<a href="#typedef-members">Typedefs</a> |
<a href="#func-members">Functions</a> </div>
<div class="headertitle">
<h1>include/class.h File Reference</h1> </div>
</div>
<div class="contents">
<div class="textblock"><code>#include <stdarg.h></code><br/>
<code>#include <sys/types.h></code><br/>
<code>#include <string.h></code><br/>
<code>#include <assert.h></code><br/>
<code>#include "<a class="el" href="interface_8h_source.html">interface.h</a>"</code><br/>
</div><div class="textblock"><div class="dynheader">
Include dependency graph for class.h:</div>
<div class="dyncontent">
<div class="center"><img src="class_8h__incl.png" border="0" usemap="#include_2class_8h" alt=""/></div>
<map name="include_2class_8h" id="include_2class_8h">
<area shape="rect" id="node11" href="interface_8h.html" title="interface.h" alt="" coords="333,83,416,111"/></map>
</div>
</div><div class="textblock"><div class="dynheader">
This graph shows which files directly or indirectly include this file:</div>
<div class="dyncontent">
<div class="center"><img src="class_8h__dep__incl.png" border="0" usemap="#include_2class_8hdep" alt=""/></div>
<map name="include_2class_8hdep" id="include_2class_8hdep">
<area shape="rect" id="node3" href="logger_8h.html" title="include/logger.h" alt="" coords="80,83,195,111"/><area shape="rect" id="node5" href="socket_8h.html" title="include/socket.h" alt="" coords="5,161,123,189"/><area shape="rect" id="node7" href="server_8h.html" title="include/server.h" alt="" coords="103,238,217,266"/></map>
</div>
</div>
<p><a href="class_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="nested-classes"></a>
Data Structures</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct  </td><td class="memItemRight" valign="bottom"><a class="el" href="structclass.html">class</a></td></tr>
<tr><td colspan="2"><h2><a name="define-members"></a>
Defines</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a04ec2c53aa9fcdb5b58dc8e9d552dec0">_ISOC99_SOURCE</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a28c4c4c1ebf62795262a3553d59e8bff">CLASS_MAGIC</a>   0xFEFE</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#ab12c2142e0ec3f4f19a03b3879c67f32">CLASS</a>(name)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a45e588b871b5b73461805ab4a5c59aa5">EXTENDS</a>(parent)   const char _[sizeof(struct c_##parent)]</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#ab9f9098d95379c04d979721396dabf68">_NULL</a>   NULL</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a509b4880afb25bb862c448d7a71e7afe">CREATE_CLASS</a>(name, _parent,...)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a2e9a0b177e4115cc7e547b51ac35c5af">_CALL</a>(object, _iface, method,...)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#ada752d9d1fdbf84e978606e8999c762d">CALL</a>(object, _iface, method,...)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a06fb0f2e08d1cbacbed6784319e7c3fc">RETCALL</a>(object, _iface, method, ret,...)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#adb99542d8748b5108322ccb26bb367e0">IFACE_GET</a>(<a class="el" href="structclass.html">class</a>, iface)   (interfaceGet(&((<a class="el" href="structclass.html">class</a>)->impl),(iface)))</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a80e924aca338b869530dde0a9389e916">IFACE_EXISTS</a>(<a class="el" href="structclass.html">class</a>, iface)   (NULL != IFACE_GET((<a class="el" href="structclass.html">class</a>),(iface)))</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a5ea9893a0e62748b9d1154d5b77abed1">HAS_PARENT</a>(<a class="el" href="structclass.html">class</a>)   (NULL != ((<a class="el" href="structclass.html">class</a>)->parent))</td></tr>
<tr><td colspan="2"><h2><a name="typedef-members"></a>
Typedefs</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef void(* </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#aa0ba47bce818b20155a8ef17a1fdc35c">fptr_classInit</a> )(void)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef struct <a class="el" href="structclass.html">class</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a68df9f6e346c5fad9f61bb2557d1d832">class_ptr</a></td></tr>
<tr><td colspan="2"><h2><a name="func-members"></a>
Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#ad96186de45579eb423ab318a5caaf62f">class_getInterface</a> (<a class="el" href="structclass.html">class_ptr</a> *, <a class="el" href="structinterface.html">iface_ptr</a>)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="structclass.html">class_ptr</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="class_8h.html#a1f382a42de272d5cc4d6bb5b17db6ede">class_getClass</a> (void *)</td></tr>
</table>
<hr/><h2>Define Documentation</h2>
<a class="anchor" id="a2e9a0b177e4115cc7e547b51ac35c5af"></a><!-- doxytag: member="class.h::_CALL" ref="a2e9a0b177e4115cc7e547b51ac35c5af" args="(object, _iface, method,...)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define _CALL</td>
<td>(</td>
<td class="paramtype"> </td>
<td class="paramname">object, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">_iface, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">method, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname"><em>...</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<b>Value:</b><div class="fragment"><pre class="fragment"><a class="code" href="structclass.html">class_ptr</a> <span class="keyword">class </span>= <a class="code" href="class_8h.html#a1f382a42de272d5cc4d6bb5b17db6ede">class_getClass</a>((object)); \
<span class="keyword">struct </span>i_##_iface * iface; \
<span class="keywordflow">if</span> (<a class="code" href="structclass.html">class</a>-><a class="code" href="structclass.html#a744967ad02b74a9464c1224c7fa05b23">init</a>) <span class="keyword">class</span>-><a class="code" href="structclass.html#a744967ad02b74a9464c1224c7fa05b23">init</a>(); \
iface = (<span class="keyword">struct </span>i_##_iface *)<a class="code" href="class_8h.html#ad96186de45579eb423ab318a5caaf62f">class_getInterface</a>(&<span class="keyword">class</span>, &i_##_iface); \
<span class="keywordflow">while</span> ((NULL == iface || NULL == iface->method) && <a class="code" href="class_8h.html#a5ea9893a0e62748b9d1154d5b77abed1">HAS_PARENT</a>(<span class="keyword">class</span>)) { \
<span class="keyword">class </span>= <a class="code" href="structclass.html">class</a>-><a class="code" href="structclass.html#a97f697cb86be7a39d4477e971074ae6e">parent</a>; \
<span class="keywordflow">if</span> (<a class="code" href="structclass.html">class</a>-><a class="code" href="structclass.html#a744967ad02b74a9464c1224c7fa05b23">init</a>) <span class="keyword">class</span>-><a class="code" href="structclass.html#a744967ad02b74a9464c1224c7fa05b23">init</a>(); \
iface = (<span class="keyword">struct </span>i_##_iface *)<a class="code" href="class_8h.html#ad96186de45579eb423ab318a5caaf62f">class_getInterface</a>(&<span class="keyword">class</span>, &i_##_iface); \
}; \
assert(NULL != iface->method);
</pre></div><p>: actually i use gcc feature ## for variadoc... think about a way to make this standard. </p>
<p>Definition at line <a class="el" href="class_8h_source.html#l00043">43</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="a04ec2c53aa9fcdb5b58dc8e9d552dec0"></a><!-- doxytag: member="class.h::_ISOC99_SOURCE" ref="a04ec2c53aa9fcdb5b58dc8e9d552dec0" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define _ISOC99_SOURCE</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8h_source.html#l00011">11</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="ab9f9098d95379c04d979721396dabf68"></a><!-- doxytag: member="class.h::_NULL" ref="ab9f9098d95379c04d979721396dabf68" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define _NULL   NULL</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8h_source.html#l00024">24</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="ada752d9d1fdbf84e978606e8999c762d"></a><!-- doxytag: member="class.h::CALL" ref="ada752d9d1fdbf84e978606e8999c762d" args="(object, _iface, method,...)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define CALL</td>
<td>(</td>
<td class="paramtype"> </td>
<td class="paramname">object, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">_iface, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">method, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname"><em>...</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<b>Value:</b><div class="fragment"><pre class="fragment"><span class="keywordflow">do</span> { \
<a class="code" href="class_8h.html#a2e9a0b177e4115cc7e547b51ac35c5af">_CALL</a>(<span class="keywordtype">object</span>, _iface, method, ##__VA_ARGS__); \
iface->method(<span class="keywordtype">object</span>, ##__VA_ARGS__); \
} <span class="keywordflow">while</span>(0)
</pre></div>
<p>Definition at line <a class="el" href="class_8h_source.html#l00055">55</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="ab12c2142e0ec3f4f19a03b3879c67f32"></a><!-- doxytag: member="class.h::CLASS" ref="ab12c2142e0ec3f4f19a03b3879c67f32" args="(name)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define CLASS</td>
<td>(</td>
<td class="paramtype"> </td>
<td class="paramname">name</td><td>)</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<b>Value:</b><div class="fragment"><pre class="fragment"><span class="keyword">struct </span>c_##name; \
<span class="keyword">typedef</span> <span class="keyword">struct </span>c_##name * name; \
<span class="keyword">extern</span> <span class="keyword">struct </span><a class="code" href="structclass.html">class</a> * <span class="keyword">const</span> _##name; \
<span class="keyword">struct </span>c_##name
</pre></div>
<p>Definition at line <a class="el" href="class_8h_source.html#l00015">15</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="a28c4c4c1ebf62795262a3553d59e8bff"></a><!-- doxytag: member="class.h::CLASS_MAGIC" ref="a28c4c4c1ebf62795262a3553d59e8bff" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define CLASS_MAGIC   0xFEFE</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8h_source.html#l00013">13</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="a509b4880afb25bb862c448d7a71e7afe"></a><!-- doxytag: member="class.h::CREATE_CLASS" ref="a509b4880afb25bb862c448d7a71e7afe" args="(name, _parent,...)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define CREATE_CLASS</td>
<td>(</td>
<td class="paramtype"> </td>
<td class="paramname">name, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">_parent, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname"><em>...</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<b>Value:</b><div class="fragment"><pre class="fragment"><span class="keyword">static</span> <span class="keyword">struct </span><a class="code" href="structclass.html">class</a> c_##name; \
<span class="keyword">static</span> <span class="keywordtype">void</span> _classInit_(<span class="keywordtype">void</span>) { \
c_##name.<a class="code" href="structclass.html#a97f697cb86be7a39d4477e971074ae6e">parent</a> = _##_parent; \
c_##name.<a class="code" href="structclass.html#a744967ad02b74a9464c1224c7fa05b23">init</a> = NULL; \
} \
<span class="keyword">static</span> <span class="keyword">struct </span><a class="code" href="structclass.html">class</a> c_##name = { \
<a class="code" href="class_8h.html#a28c4c4c1ebf62795262a3553d59e8bff">CLASS_MAGIC</a>, \
NULL, \
<span class="keyword">sizeof</span>(<span class="keyword">struct </span>c_##name), \
_classInit_, \
<a class="code" href="interface_8h.html#a6e8015282e5aac5747daff5bb71d8601">INIT_IMPL</a>(__VA_ARGS__) \
}; <span class="keyword">struct </span><a class="code" href="structclass.html">class</a> * <span class="keyword">const</span> _##name = &c_##name
</pre></div>
<p>Definition at line <a class="el" href="class_8h_source.html#l00025">25</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="a45e588b871b5b73461805ab4a5c59aa5"></a><!-- doxytag: member="class.h::EXTENDS" ref="a45e588b871b5b73461805ab4a5c59aa5" args="(parent)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define EXTENDS</td>
<td>(</td>
<td class="paramtype"> </td>
<td class="paramname">parent</td><td>)</td>
<td>   const char _[sizeof(struct c_##parent)]</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8h_source.html#l00021">21</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="a5ea9893a0e62748b9d1154d5b77abed1"></a><!-- doxytag: member="class.h::HAS_PARENT" ref="a5ea9893a0e62748b9d1154d5b77abed1" args="(class)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define HAS_PARENT</td>
<td>(</td>
<td class="paramtype"> </td>
<td class="paramname"><a class="el" href="structclass.html">class</a></td><td>)</td>
<td>   (NULL != ((<a class="el" href="structclass.html">class</a>)->parent))</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8h_source.html#l00071">71</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="a80e924aca338b869530dde0a9389e916"></a><!-- doxytag: member="class.h::IFACE_EXISTS" ref="a80e924aca338b869530dde0a9389e916" args="(class, iface)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define IFACE_EXISTS</td>
<td>(</td>
<td class="paramtype"> </td>
<td class="paramname"><a class="el" href="structclass.html">class</a>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">iface </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td>   (NULL != IFACE_GET((<a class="el" href="structclass.html">class</a>),(iface)))</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8h_source.html#l00069">69</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="adb99542d8748b5108322ccb26bb367e0"></a><!-- doxytag: member="class.h::IFACE_GET" ref="adb99542d8748b5108322ccb26bb367e0" args="(class, iface)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define IFACE_GET</td>
<td>(</td>
<td class="paramtype"> </td>
<td class="paramname"><a class="el" href="structclass.html">class</a>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">iface </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td>   (interfaceGet(&((<a class="el" href="structclass.html">class</a>)->impl),(iface)))</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8h_source.html#l00068">68</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="a06fb0f2e08d1cbacbed6784319e7c3fc"></a><!-- doxytag: member="class.h::RETCALL" ref="a06fb0f2e08d1cbacbed6784319e7c3fc" args="(object, _iface, method, ret,...)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define RETCALL</td>
<td>(</td>
<td class="paramtype"> </td>
<td class="paramname">object, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">_iface, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">method, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname">ret, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"> </td>
<td class="paramname"><em>...</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<b>Value:</b><div class="fragment"><pre class="fragment"><span class="keywordflow">do</span> { \
<a class="code" href="class_8h.html#a2e9a0b177e4115cc7e547b51ac35c5af">_CALL</a>(<span class="keywordtype">object</span>, _iface, method, ##__VA_ARGS__); \
ret = iface->method(<span class="keywordtype">object</span>, ##__VA_ARGS__); \
} <span class="keywordflow">while</span>(0)
</pre></div>
<p>Definition at line <a class="el" href="class_8h_source.html#l00061">61</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<hr/><h2>Typedef Documentation</h2>
<a class="anchor" id="a68df9f6e346c5fad9f61bb2557d1d832"></a><!-- doxytag: member="class.h::class_ptr" ref="a68df9f6e346c5fad9f61bb2557d1d832" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef struct <a class="el" href="structclass.html">class</a>* <a class="el" href="structclass.html">class_ptr</a></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8h_source.html#l00076">76</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<a class="anchor" id="aa0ba47bce818b20155a8ef17a1fdc35c"></a><!-- doxytag: member="class.h::fptr_classInit" ref="aa0ba47bce818b20155a8ef17a1fdc35c" args=")(void)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef void(* <a class="el" href="class_8h.html#aa0ba47bce818b20155a8ef17a1fdc35c">fptr_classInit</a>)(void)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8h_source.html#l00073">73</a> of file <a class="el" href="class_8h_source.html">class.h</a>.</p>
</div>
</div>
<hr/><h2>Function Documentation</h2>
<a class="anchor" id="a1f382a42de272d5cc4d6bb5b17db6ede"></a><!-- doxytag: member="class.h::class_getClass" ref="a1f382a42de272d5cc4d6bb5b17db6ede" args="(void *)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="structclass.html">class_ptr</a> class_getClass </td>
<td>(</td>
<td class="paramtype">void * </td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8c_source.html#l00021">21</a> of file <a class="el" href="class_8c_source.html">class.c</a>.</p>
<div class="fragment"><pre class="fragment">{
<span class="keywordflow">return</span> *(<a class="code" href="structclass.html">class_ptr</a> *)(<span class="keywordtype">object</span> - <span class="keyword">sizeof</span>(<span class="keywordtype">void</span>*));
}
</pre></div>
<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_8h_a1f382a42de272d5cc4d6bb5b17db6ede_icgraph.png" border="0" usemap="#class_8h_a1f382a42de272d5cc4d6bb5b17db6ede_icgraph" alt=""/></div>
<map name="class_8h_a1f382a42de272d5cc4d6bb5b17db6ede_icgraph" id="class_8h_a1f382a42de272d5cc4d6bb5b17db6ede_icgraph">
<area shape="rect" id="node3" href="interface_2class_8c.html#ada46f0179448063a30f6f219270bf1e0" title="classClone" alt="" coords="167,5,252,33"/></map>
</div>
</p>
</div>
</div>
<a class="anchor" id="ad96186de45579eb423ab318a5caaf62f"></a><!-- doxytag: member="class.h::class_getInterface" ref="ad96186de45579eb423ab318a5caaf62f" args="(class_ptr *, iface_ptr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void* class_getInterface </td>
<td>(</td>
<td class="paramtype"><a class="el" href="structclass.html">class_ptr</a> * </td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structinterface.html">iface_ptr</a> </td>
<td class="paramname"> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Definition at line <a class="el" href="class_8c_source.html#l00008">8</a> of file <a class="el" href="class_8c_source.html">class.c</a>.</p>
<div class="fragment"><pre class="fragment">{
<span class="keywordtype">void</span> * iface = (<span class="keywordtype">void</span> *)<a class="code" href="class_8h.html#adb99542d8748b5108322ccb26bb367e0">IFACE_GET</a>(*<span class="keyword">class</span>, _iface);
<span class="keywordflow">while</span>(NULL == iface && <a class="code" href="class_8h.html#a5ea9893a0e62748b9d1154d5b77abed1">HAS_PARENT</a>(*<span class="keyword">class</span>)) {
*<span class="keyword">class </span>= (*<span class="keyword">class</span>)-><a class="code" href="structclass.html#a97f697cb86be7a39d4477e971074ae6e">parent</a>;
iface = (<span class="keywordtype">void</span> *)<a class="code" href="class_8h.html#adb99542d8748b5108322ccb26bb367e0">IFACE_GET</a>(*<span class="keyword">class</span>, _iface);
}
<span class="keywordflow">return</span> iface;
}
</pre></div>
</div>
</div>
</div>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="class_8h.html">class.h</a> </li>
<li class="footer">Generated on Wed Feb 8 2012 13:04:39 for server by 
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.3 </li>
</ul>
</div>
<!--- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Data Structures</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark"> </span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark"> </span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark"> </span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark"> </span>Defines</a></div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
</body>
</html>