This file is indexed.

/usr/share/doc/libucommon-dev/a00037.html is in libucommon-doc 3.2.0-0ubuntu1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
<!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>UCommon: ucc::cidr Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generated by Doxygen 1.6.3 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="main.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li><a href="examples.html"><span>Examples</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li><a href="classes.html"><span>Data&nbsp;Structure&nbsp;Index</span></a></li>
      <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
    </ul>
  </div>
  <div class="navpath"><a class="el" href="a00214.html">ucc</a>::<a class="el" href="a00037.html">cidr</a>
  </div>
</div>
<div class="contents">
<h1>ucc::cidr Class Reference</h1><!-- doxytag: class="ucc::cidr" --><!-- doxytag: inherits="ucc::LinkedObject" -->
<p>A class to hold internet segment routing rules.  
<a href="#_details">More...</a></p>

<p><code>#include &lt;<a class="el" href="a00205_source.html">socket.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for ucc::cidr:</div>
<div class="dynsection">
<div class="center"><img src="a00369.png" border="0" usemap="#ucc_1_1cidr_inherit__map" alt="Inheritance graph"/></div>
<map name="ucc_1_1cidr_inherit__map" id="ucc_1_1cidr_inherit__map">
<area shape="rect" id="node2" href="a00069.html" title="Common base class for all objects that can be formed into a linked list." alt="" coords="5,83,139,112"/><area shape="rect" id="node4" href="a00093.html" title="A common base class for all managed objects." alt="" coords="25,5,119,35"/></map>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>
<div class="dynheader">
Collaboration diagram for ucc::cidr:</div>
<div class="dynsection">
<div class="center"><img src="a00370.png" border="0" usemap="#ucc_1_1cidr_coll__map" alt="Collaboration graph"/></div>
<map name="ucc_1_1cidr_coll__map" id="ucc_1_1cidr_coll__map">
<area shape="rect" id="node2" href="a00069.html" title="Common base class for all objects that can be formed into a linked list." alt="" coords="5,96,139,125"/><area shape="rect" id="node4" href="a00093.html" title="A common base class for all managed objects." alt="" coords="25,5,119,35"/><area shape="rect" id="node7" href="a00014.html" title="An object that holds ipv4 or ipv6 binary encoded host addresses." alt="" coords="216,96,352,125"/></map>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td colspan="2"><h2>Public Types</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4a98545d3149bdf1e916556799184742"></a><!-- doxytag: member="ucc::cidr::policy" ref="a4a98545d3149bdf1e916556799184742" args="" -->
typedef <a class="el" href="a00069.html">LinkedObject</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a4a98545d3149bdf1e916556799184742">policy</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">A convenience type for using a pointer to a linked list as a policy chain. <br/></td></tr>
<tr><td colspan="2"><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a5d2b549d1726832192b9f7b6ee1c2764">cidr</a> (const <a class="el" href="a00037.html">cidr</a> &amp;existing)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Construct a copy of an existing cidr.  <a href="#a5d2b549d1726832192b9f7b6ee1c2764"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a191546ad35d219be2ef1ea5400a0994f">cidr</a> (<a class="el" href="a00069.html">policy</a> **<a class="el" href="a00069.html">policy</a>, const char *<a class="el" href="a00157.html">string</a>, const char *name)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Create a named cidr entry on a specified policy chain.  <a href="#a191546ad35d219be2ef1ea5400a0994f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#aa8579f72711c6c130a6db14e6afcf155">cidr</a> (<a class="el" href="a00069.html">policy</a> **<a class="el" href="a00069.html">policy</a>, const char *<a class="el" href="a00157.html">string</a>)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Create an unnamed cidr entry on a specified policy chain.  <a href="#aa8579f72711c6c130a6db14e6afcf155"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a5ce14b5fc89e36b881877a2284ad66fe">cidr</a> (const char *<a class="el" href="a00157.html">string</a>)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Create an unlinked cidr from a string.  <a href="#a5ce14b5fc89e36b881877a2284ad66fe"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a2f5d013f21a4d21c8a5c54e9a65b9e7c"></a><!-- doxytag: member="ucc::cidr::cidr" ref="a2f5d013f21a4d21c8a5c54e9a65b9e7c" args="()" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a2f5d013f21a4d21c8a5c54e9a65b9e7c">cidr</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Create an uninitialized cidr. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="a00014.html">inethostaddr_t</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#ae815ed69a3c52e37b9651a2aab99b793">getBroadcast</a> (void) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the broadcast host address represented by our cidr.  <a href="#ae815ed69a3c52e37b9651a2aab99b793"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a69419b44cfc9155186dbf2124518ceab">getFamily</a> (void) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the address family of our cidr block object.  <a href="#a69419b44cfc9155186dbf2124518ceab"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">unsigned&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a13351f9efb6279f05f05a4d3609dfa74">getMask</a> (void) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the number of bits in the cidr bitmask.  <a href="#a13351f9efb6279f05f05a4d3609dfa74"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">const char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a07b6ba9aea9ceba920ea58d32f6f7874">getName</a> (void) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the saved name of our cidr.  <a href="#a07b6ba9aea9ceba920ea58d32f6f7874"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="a00014.html">inethostaddr_t</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a75de7df903a35b755866349d794e807a">getNetmask</a> (void) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the effective network mask for our cidr block.  <a href="#a75de7df903a35b755866349d794e807a"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="a00014.html">inethostaddr_t</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a9d2e8638edf4a889b0f372d8bc4b4466">getNetwork</a> (void) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the network host base address of our cidr block.  <a href="#a9d2e8638edf4a889b0f372d8bc4b4466"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a0d0d2908be0cfa823f07bca82dbe7ca9">isMember</a> (const struct sockaddr *address) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Test if a given socket address falls within this cidr.  <a href="#a0d0d2908be0cfa823f07bca82dbe7ca9"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#ab04659f9694865a447683305fcc63b90">operator!=</a> (const struct sockaddr *address) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Test if a given socket address falls outside this cidr.  <a href="#ab04659f9694865a447683305fcc63b90"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a1591fa9532e4e750d6d7d9397347f9bc">operator==</a> (const struct sockaddr *address) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Test if a given socket address falls within this cidr.  <a href="#a1591fa9532e4e750d6d7d9397347f9bc"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#afa7bba51cc338e89a945838023ad7435">set</a> (const char *<a class="el" href="a00157.html">string</a>)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set our cidr to a string address.  <a href="#afa7bba51cc338e89a945838023ad7435"></a><br/></td></tr>
<tr><td colspan="2"><h2>Static Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static <a class="el" href="a00037.html">cidr</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#ab75c78aac13a6775b52bc219feaa3872">container</a> (<a class="el" href="a00069.html">policy</a> *<a class="el" href="a00069.html">policy</a>, const struct sockaddr *address)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the largest container cidr entry in a list that matches the socket address.  <a href="#ab75c78aac13a6775b52bc219feaa3872"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static <a class="el" href="a00037.html">cidr</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00037.html#a41898ff78ed3ea3fa79516cac97d432a">find</a> (<a class="el" href="a00069.html">policy</a> *<a class="el" href="a00069.html">policy</a>, const struct sockaddr *address)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find the smallest cidr entry in a list that matches the socket address.  <a href="#a41898ff78ed3ea3fa79516cac97d432a"></a><br/></td></tr>
<tr><td colspan="2"><h2>Protected Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab6c5c713b8694effea938e1bde6a596b"></a><!-- doxytag: member="ucc::cidr::getMask" ref="ab6c5c713b8694effea938e1bde6a596b" args="(const char *cp) const " -->
unsigned&nbsp;</td><td class="memItemRight" valign="bottom"><b>getMask</b> (const char *cp) const </td></tr>
<tr><td colspan="2"><h2>Protected Attributes</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a08376725c8234d3393ab60b634635d56"></a><!-- doxytag: member="ucc::cidr::family" ref="a08376725c8234d3393ab60b634635d56" args="" -->
int&nbsp;</td><td class="memItemRight" valign="bottom"><b>family</b></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a6a083539f1e19fae677f940108e13d1c"></a><!-- doxytag: member="ucc::cidr::name" ref="a6a083539f1e19fae677f940108e13d1c" args="[16]" -->
char&nbsp;</td><td class="memItemRight" valign="bottom"><b>name</b> [16]</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aac6d9d09d31ab2c4d10bbc3a6e8e7967"></a><!-- doxytag: member="ucc::cidr::netmask" ref="aac6d9d09d31ab2c4d10bbc3a6e8e7967" args="" -->
<a class="el" href="a00014.html">inethostaddr_t</a>&nbsp;</td><td class="memItemRight" valign="bottom"><b>netmask</b></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac2247777f96d0fa9aaad6d71c56cfe90"></a><!-- doxytag: member="ucc::cidr::network" ref="ac2247777f96d0fa9aaad6d71c56cfe90" args="" -->
<a class="el" href="a00014.html">inethostaddr_t</a>&nbsp;</td><td class="memItemRight" valign="bottom"><b>network</b></td></tr>
</table>
<hr/><a name="_details"></a><h2>Detailed Description</h2>
<p>A class to hold internet segment routing rules. </p>
<p>This class can be used to provide a stand-alone representation of a cidr block of internet addresses or chained together into some form of access control list. The cidr class can hold segments for both IPV4 and IPV6 addresses. The class accepts cidr's defined as C strings, typically in the form of address/bits or address/submask. These routines auto-detect ipv4 and ipv6 addresses. </p>
<dl class="author"><dt><b>Author:</b></dt><dd>David Sugar &lt;<a href="mailto:dyfet@gnutelephony.org">dyfet@gnutelephony.org</a>&gt; </dd></dl>

<p>Definition at line <a class="el" href="a00205_source.html#l00150">150</a> of file <a class="el" href="a00205_source.html">socket.h</a>.</p>
<hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a5ce14b5fc89e36b881877a2284ad66fe"></a><!-- doxytag: member="ucc::cidr::cidr" ref="a5ce14b5fc89e36b881877a2284ad66fe" args="(const char *string)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ucc::cidr::cidr </td>
          <td>(</td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>string</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Create an unlinked cidr from a string. </p>
<p>The string is typically in the form base-host-address/range, where range might be a bit count or a network mask. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>string</em>&nbsp;</td><td>for cidr block. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="aa8579f72711c6c130a6db14e6afcf155"></a><!-- doxytag: member="ucc::cidr::cidr" ref="aa8579f72711c6c130a6db14e6afcf155" args="(policy **policy, const char *string)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ucc::cidr::cidr </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="a00069.html">policy</a> **&nbsp;</td>
          <td class="paramname"> <em>policy</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>string</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Create an unnamed cidr entry on a specified policy chain. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>policy</em>&nbsp;</td><td>chain to link cidr to. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>string</em>&nbsp;</td><td>for cidr block. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a191546ad35d219be2ef1ea5400a0994f"></a><!-- doxytag: member="ucc::cidr::cidr" ref="a191546ad35d219be2ef1ea5400a0994f" args="(policy **policy, const char *string, const char *name)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ucc::cidr::cidr </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="a00069.html">policy</a> **&nbsp;</td>
          <td class="paramname"> <em>policy</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>string</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>name</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Create a named cidr entry on a specified policy chain. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>policy</em>&nbsp;</td><td>chain to link cidr to. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>string</em>&nbsp;</td><td>for cidr block. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>name</em>&nbsp;</td><td>of this policy object. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a5d2b549d1726832192b9f7b6ee1c2764"></a><!-- doxytag: member="ucc::cidr::cidr" ref="a5d2b549d1726832192b9f7b6ee1c2764" args="(const cidr &amp;existing)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ucc::cidr::cidr </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="a00037.html">cidr</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>existing</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Construct a copy of an existing cidr. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>existing</em>&nbsp;</td><td>cidr we copy from. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="ab75c78aac13a6775b52bc219feaa3872"></a><!-- doxytag: member="ucc::cidr::container" ref="ab75c78aac13a6775b52bc219feaa3872" args="(policy *policy, const struct sockaddr *address)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">static <a class="el" href="a00037.html">cidr</a>* ucc::cidr::container </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="a00069.html">policy</a> *&nbsp;</td>
          <td class="paramname"> <em>policy</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const struct sockaddr *&nbsp;</td>
          <td class="paramname"> <em>address</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [static]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the largest container cidr entry in a list that matches the socket address. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>policy</em>&nbsp;</td><td>chain to search. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>address</em>&nbsp;</td><td>to search for. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>largest cidr or NULL if none match. </dd></dl>

</div>
</div>
<a class="anchor" id="a41898ff78ed3ea3fa79516cac97d432a"></a><!-- doxytag: member="ucc::cidr::find" ref="a41898ff78ed3ea3fa79516cac97d432a" args="(policy *policy, const struct sockaddr *address)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">static <a class="el" href="a00037.html">cidr</a>* ucc::cidr::find </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="a00069.html">policy</a> *&nbsp;</td>
          <td class="paramname"> <em>policy</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const struct sockaddr *&nbsp;</td>
          <td class="paramname"> <em>address</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [static]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Find the smallest cidr entry in a list that matches the socket address. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>policy</em>&nbsp;</td><td>chain to search. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>address</em>&nbsp;</td><td>to search for. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>smallest cidr or NULL if none match. </dd></dl>

</div>
</div>
<a class="anchor" id="ae815ed69a3c52e37b9651a2aab99b793"></a><!-- doxytag: member="ucc::cidr::getBroadcast" ref="ae815ed69a3c52e37b9651a2aab99b793" args="(void) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="a00014.html">inethostaddr_t</a> ucc::cidr::getBroadcast </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the broadcast host address represented by our cidr. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>binary broadcast host address. </dd></dl>

</div>
</div>
<a class="anchor" id="a69419b44cfc9155186dbf2124518ceab"></a><!-- doxytag: member="ucc::cidr::getFamily" ref="a69419b44cfc9155186dbf2124518ceab" args="(void) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int ucc::cidr::getFamily </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the address family of our cidr block object. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>family of our cidr. </dd></dl>

<p>Definition at line <a class="el" href="a00205_source.html#l00229">229</a> of file <a class="el" href="a00205_source.html">socket.h</a>.</p>

</div>
</div>
<a class="anchor" id="a13351f9efb6279f05f05a4d3609dfa74"></a><!-- doxytag: member="ucc::cidr::getMask" ref="a13351f9efb6279f05f05a4d3609dfa74" args="(void) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">unsigned ucc::cidr::getMask </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the number of bits in the cidr bitmask. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>bit mask of cidr. </dd></dl>

</div>
</div>
<a class="anchor" id="a07b6ba9aea9ceba920ea58d32f6f7874"></a><!-- doxytag: member="ucc::cidr::getName" ref="a07b6ba9aea9ceba920ea58d32f6f7874" args="(void) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const char* ucc::cidr::getName </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the saved name of our cidr. </p>
<p>This is typically used with find when the same policy name might be associated with multiple non- overlapping cidr blocks. A typical use might to have a cidr block like 127/8 named "localdomain", as well as the ipv6 "::1". </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>name of cidr. </dd></dl>

<p>Definition at line <a class="el" href="a00205_source.html#l00222">222</a> of file <a class="el" href="a00205_source.html">socket.h</a>.</p>

</div>
</div>
<a class="anchor" id="a75de7df903a35b755866349d794e807a"></a><!-- doxytag: member="ucc::cidr::getNetmask" ref="a75de7df903a35b755866349d794e807a" args="(void) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="a00014.html">inethostaddr_t</a> ucc::cidr::getNetmask </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the effective network mask for our cidr block. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>binary network mask for our cidr. </dd></dl>

<p>Definition at line <a class="el" href="a00205_source.html#l00243">243</a> of file <a class="el" href="a00205_source.html">socket.h</a>.</p>

</div>
</div>
<a class="anchor" id="a9d2e8638edf4a889b0f372d8bc4b4466"></a><!-- doxytag: member="ucc::cidr::getNetwork" ref="a9d2e8638edf4a889b0f372d8bc4b4466" args="(void) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="a00014.html">inethostaddr_t</a> ucc::cidr::getNetwork </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the network host base address of our cidr block. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>binary network host address. </dd></dl>

<p>Definition at line <a class="el" href="a00205_source.html#l00236">236</a> of file <a class="el" href="a00205_source.html">socket.h</a>.</p>

</div>
</div>
<a class="anchor" id="a0d0d2908be0cfa823f07bca82dbe7ca9"></a><!-- doxytag: member="ucc::cidr::isMember" ref="a0d0d2908be0cfa823f07bca82dbe7ca9" args="(const struct sockaddr *address) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool ucc::cidr::isMember </td>
          <td>(</td>
          <td class="paramtype">const struct sockaddr *&nbsp;</td>
          <td class="paramname"> <em>address</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Test if a given socket address falls within this cidr. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>address</em>&nbsp;</td><td>of socket to test. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>true if address is within cidr. </dd></dl>

</div>
</div>
<a class="anchor" id="ab04659f9694865a447683305fcc63b90"></a><!-- doxytag: member="ucc::cidr::operator!=" ref="ab04659f9694865a447683305fcc63b90" args="(const struct sockaddr *address) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool ucc::cidr::operator!= </td>
          <td>(</td>
          <td class="paramtype">const struct sockaddr *&nbsp;</td>
          <td class="paramname"> <em>address</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Test if a given socket address falls outside this cidr. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>address</em>&nbsp;</td><td>of socket to test. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>true if address is outside cidr. </dd></dl>

<p>Definition at line <a class="el" href="a00205_source.html#l00284">284</a> of file <a class="el" href="a00205_source.html">socket.h</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
<div class="center"><img src="a00037_ab04659f9694865a447683305fcc63b90_cgraph.png" border="0" usemap="#a00037_ab04659f9694865a447683305fcc63b90_cgraph_map" alt=""></div>
<map name="a00037_ab04659f9694865a447683305fcc63b90_cgraph_map" id="a00037_ab04659f9694865a447683305fcc63b90_cgraph">
<area shape="rect" id="node3" href="a00069.html#a05d733ee681c00c12951862faade90ac" title="Search to see if we are a member of a specific list." alt="" coords="208,5,413,35"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a1591fa9532e4e750d6d7d9397347f9bc"></a><!-- doxytag: member="ucc::cidr::operator==" ref="a1591fa9532e4e750d6d7d9397347f9bc" args="(const struct sockaddr *address) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool ucc::cidr::operator== </td>
          <td>(</td>
          <td class="paramtype">const struct sockaddr *&nbsp;</td>
          <td class="paramname"> <em>address</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Test if a given socket address falls within this cidr. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>address</em>&nbsp;</td><td>of socket to test. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>true if address is within cidr. </dd></dl>

<p>Definition at line <a class="el" href="a00205_source.html#l00276">276</a> of file <a class="el" href="a00205_source.html">socket.h</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
<div class="center"><img src="a00037_a1591fa9532e4e750d6d7d9397347f9bc_cgraph.png" border="0" usemap="#a00037_a1591fa9532e4e750d6d7d9397347f9bc_cgraph_map" alt=""></div>
<map name="a00037_a1591fa9532e4e750d6d7d9397347f9bc_cgraph_map" id="a00037_a1591fa9532e4e750d6d7d9397347f9bc_cgraph">
<area shape="rect" id="node3" href="a00069.html#a05d733ee681c00c12951862faade90ac" title="Search to see if we are a member of a specific list." alt="" coords="213,5,419,35"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="afa7bba51cc338e89a945838023ad7435"></a><!-- doxytag: member="ucc::cidr::set" ref="afa7bba51cc338e89a945838023ad7435" args="(const char *string)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void ucc::cidr::set </td>
          <td>(</td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>string</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Set our cidr to a string address. </p>
<p>Replaces prior value. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>string</em>&nbsp;</td><td>to set for cidr. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>ucommon/<a class="el" href="a00205_source.html">socket.h</a></li>
</ul>
</div>
<hr class="footer"/><address style="text-align: right;"><small>Generated on Tue Jul 6 08:22:26 2010 for UCommon by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address>
</body>
</html>