/usr/share/doc/php5-common/PEAR/Structures_Graph/docs/html/Structures_Graph/Structures_Graph_Node.html is in php-pear 5.3.10-1ubuntu3.26.
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 | <?xml version="1.0" encoding="iso-8859-1"?>
<!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>
<!-- template designed by Marco Von Ballmoos -->
<title>Docs For Class Structures_Graph_Node</title>
<link rel="stylesheet" href="../media/stylesheet.css" />
<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
</head>
<body>
<div class="page-body">
<h2 class="class-name">Class Structures_Graph_Node</h2>
<a name="sec-description"></a>
<div class="info-box">
<div class="info-box-title">Description</div>
<div class="nav-bar">
<span class="disabled">Description</span> |
<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
</div>
<div class="info-box-body">
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">The Structures_Graph_Node class represents a Node that can be member of a graph node set.</p>
<p class="description"><p>A graph node can contain data. Under this API, the node contains default data, and key index data. It behaves, thus, both as a regular data node, and as a dictionary (or associative array) node.</p><p>Regular data is accessed via getData and setData. Key indexed data is accessed via getMetadata and setMetadata.</p></p>
<ul class="tags">
<li><span class="field">copyright:</span> (c) 2004 by Sérgio Carvalho</li>
<li><span class="field">author:</span> Sérgio Carvalho <<a href="mailto:sergio.carvalho@portugalmail.com">mailto:sergio.carvalho@portugalmail.com</a>></li>
</ul>
<p class="notes">
Located in <a class="field" href="_Structures_Graph_Node_php.html">/Structures/Graph/Node.php</a> (line <span class="field">57</span>)
</p>
<pre></pre>
</div>
</div>
<a name="sec-method-summary"></a>
<div class="info-box">
<div class="info-box-title">Method Summary</span></div>
<div class="nav-bar">
<a href="#sec-description">Description</a> |
<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
</div>
<div class="info-box-body">
<div class="method-summary">
<div class="method-definition">
<span class="method-result">Structures_Graph_Node</span>
<a href="#Structures_Graph_Node" title="details" class="method-name">Structures_Graph_Node</a>
()
</div>
<div class="method-definition">
<span class="method-result">boolean</span>
<a href="#connectsTo" title="details" class="method-name">connectsTo</a>
(<span class="var-type">mixed</span> <span class="var-name">&$target</span>)
</div>
<div class="method-definition">
<span class="method-result">void</span>
<a href="#connectTo" title="details" class="method-name">connectTo</a>
(<span class="var-type"><a href="../Structures_Graph/Structures_Graph.html">Structures_Graph</a></span> <span class="var-name">&$destinationNode</span>)
</div>
<div class="method-definition">
<span class="method-result">mixed</span>
<a href="#getData" title="details" class="method-name">&getData</a>
()
</div>
<div class="method-definition">
<span class="method-result"><a href="../Structures_Graph/Structures_Graph.html">Structures_Graph</a></span>
<a href="#getGraph" title="details" class="method-name">&getGraph</a>
()
</div>
<div class="method-definition">
<span class="method-result">mixed</span>
<a href="#getMetadata" title="details" class="method-name">&getMetadata</a>
(<span class="var-type">string</span> <span class="var-name">$key</span>, [<span class="var-type">boolean</span> <span class="var-name">$nullIfNonexistent</span> = <span class="var-default">false</span>])
</div>
<div class="method-definition">
<span class="method-result">array</span>
<a href="#getNeighbours" title="details" class="method-name">getNeighbours</a>
()
</div>
<div class="method-definition">
<span class="method-result">integer</span>
<a href="#inDegree" title="details" class="method-name">inDegree</a>
()
</div>
<div class="method-definition">
<span class="method-result">boolean</span>
<a href="#metadataKeyExists" title="details" class="method-name">metadataKeyExists</a>
(<span class="var-type">string</span> <span class="var-name">$key</span>)
</div>
<div class="method-definition">
<span class="method-result">integer</span>
<a href="#outDegree" title="details" class="method-name">outDegree</a>
()
</div>
<div class="method-definition">
<span class="method-result">mixed</span>
<a href="#setData" title="details" class="method-name">setData</a>
(<span class="var-type">mixed</span> <span class="var-name">$data</span>)
</div>
<div class="method-definition">
<span class="method-result">void</span>
<a href="#setGraph" title="details" class="method-name">setGraph</a>
(<span class="var-type"><a href="../Structures_Graph/Structures_Graph.html">Structures_Graph</a></span> <span class="var-name">&$graph</span>)
</div>
<div class="method-definition">
<span class="method-result">void</span>
<a href="#setMetadata" title="details" class="method-name">setMetadata</a>
(<span class="var-type">string</span> <span class="var-name">$key</span>, <span class="var-type">mixed</span> <span class="var-name">$data</span>)
</div>
<div class="method-definition">
<span class="method-result">void</span>
<a href="#unsetMetadata" title="details" class="method-name">unsetMetadata</a>
(<span class="var-type">string</span> <span class="var-name">$key</span>)
</div>
</div>
</div>
</div>
<a name="sec-methods"></a>
<div class="info-box">
<div class="info-box-title">Methods</div>
<div class="nav-bar">
<a href="#sec-description">Description</a> |
<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
</div>
<div class="info-box-body">
<A NAME='method_detail'></A>
<a name="methodStructures_Graph_Node" id="Structures_Graph_Node"><!-- --></a>
<div class="evenrow">
<div class="method-header">
<span class="method-title">Constructor Structures_Graph_Node</span> (line <span class="line-number">78</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constructor</p>
<ul class="tags">
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">Structures_Graph_Node</span>
<span class="method-name">
Structures_Graph_Node
</span>
()
</div>
</div>
<a name="methodconnectsTo" id="connectsTo"><!-- --></a>
<div class="oddrow">
<div class="method-header">
<span class="method-title">connectsTo</span> (line <span class="line-number">275</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Test wether this node has an arc to the target node</p>
<ul class="tags">
<li><span class="field">return:</span> True if the two nodes are connected</li>
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">boolean</span>
<span class="method-name">
connectsTo
</span>
(<span class="var-type">mixed</span> <span class="var-name">&$target</span>)
</div>
</div>
<a name="methodconnectTo" id="connectTo"><!-- --></a>
<div class="evenrow">
<div class="method-header">
<span class="method-title">connectTo</span> (line <span class="line-number">236</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Connect this node to another one.</p>
<p class="description"><p>If the graph is not directed, the reverse arc, connecting $destinationNode to $this is also created.</p></p>
<ul class="tags">
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">void</span>
<span class="method-name">
connectTo
</span>
(<span class="var-type"><a href="../Structures_Graph/Structures_Graph.html">Structures_Graph</a></span> <span class="var-name">&$destinationNode</span>)
</div>
<ul class="parameters">
<li>
<span class="var-type"><a href="../Structures_Graph/Structures_Graph.html">Structures_Graph</a></span>
<span class="var-name">&$destinationNode</span><span class="var-description">: Node to connect to</span> </li>
</ul>
</div>
<a name="methodgetData" id="getData"><!-- --></a>
<div class="oddrow">
<div class="method-header">
<span class="method-title">getData</span> (line <span class="line-number">119</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Node data getter.</p>
<p class="description"><p>Each graph node can contain a reference to one variable. This is the getter for that reference.</p></p>
<ul class="tags">
<li><span class="field">return:</span> Data stored in node</li>
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">mixed</span>
<span class="method-name">
&getData
</span>
()
</div>
</div>
<a name="methodgetGraph" id="getGraph"><!-- --></a>
<div class="evenrow">
<div class="method-header">
<span class="method-title">getGraph</span> (line <span class="line-number">90</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Node graph getter</p>
<ul class="tags">
<li><span class="field">return:</span> Graph where node is stored</li>
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result"><a href="../Structures_Graph/Structures_Graph.html">Structures_Graph</a></span>
<span class="method-name">
&getGraph
</span>
()
</div>
</div>
<a name="methodgetMetadata" id="getMetadata"><!-- --></a>
<div class="oddrow">
<div class="method-header">
<span class="method-title">getMetadata</span> (line <span class="line-number">171</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Node metadata getter</p>
<p class="description"><p>Each graph node can contain multiple 'metadata' entries, each stored under a different key, as in an associative array or in a dictionary. This method gets the data under the given key. If the key does not exist, an error will be thrown, so testing using metadataKeyExists might be needed.</p></p>
<ul class="tags">
<li><span class="field">return:</span> Metadata Data stored in node under given key</li>
<li><span class="field">access:</span> public</li>
<li><span class="field">see:</span> <a href="../Structures_Graph/Structures_Graph_Node.html#methodmetadataKeyExists">Structures_Graph_Node::metadataKeyExists()</a></li>
</ul>
<div class="method-signature">
<span class="method-result">mixed</span>
<span class="method-name">
&getMetadata
</span>
(<span class="var-type">string</span> <span class="var-name">$key</span>, [<span class="var-type">boolean</span> <span class="var-name">$nullIfNonexistent</span> = <span class="var-default">false</span>])
</div>
<ul class="parameters">
<li>
<span class="var-type">string</span>
<span class="var-name">$key</span><span class="var-description">: Key</span> </li>
<li>
<span class="var-type">boolean</span>
<span class="var-name">$nullIfNonexistent</span><span class="var-description">: nullIfNonexistent (defaults to false).</span> </li>
</ul>
</div>
<a name="methodgetNeighbours" id="getNeighbours"><!-- --></a>
<div class="evenrow">
<div class="method-header">
<span class="method-title">getNeighbours</span> (line <span class="line-number">262</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Return nodes connected to this one.</p>
<ul class="tags">
<li><span class="field">return:</span> Array of nodes</li>
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">array</span>
<span class="method-name">
getNeighbours
</span>
()
</div>
</div>
<a name="methodinDegree" id="inDegree"><!-- --></a>
<div class="oddrow">
<div class="method-header">
<span class="method-title">inDegree</span> (line <span class="line-number">309</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Calculate the in degree of the node.</p>
<p class="description"><p>The indegree for a node is the number of arcs entering the node. For non directed graphs, the indegree is equal to the outdegree.</p></p>
<ul class="tags">
<li><span class="field">return:</span> In degree of the node</li>
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">integer</span>
<span class="method-name">
inDegree
</span>
()
</div>
</div>
<a name="methodmetadataKeyExists" id="metadataKeyExists"><!-- --></a>
<div class="evenrow">
<div class="method-header">
<span class="method-title">metadataKeyExists</span> (line <span class="line-number">151</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Test for existence of metadata under a given key.</p>
<p class="description"><p>Each graph node can contain multiple 'metadata' entries, each stored under a different key, as in an associative array or in a dictionary. This method tests whether a given metadata key exists for this node.</p></p>
<ul class="tags">
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">boolean</span>
<span class="method-name">
metadataKeyExists
</span>
(<span class="var-type">string</span> <span class="var-name">$key</span>)
</div>
<ul class="parameters">
<li>
<span class="var-type">string</span>
<span class="var-name">$key</span><span class="var-description">: Key to test</span> </li>
</ul>
</div>
<a name="methodoutDegree" id="outDegree"><!-- --></a>
<div class="oddrow">
<div class="method-header">
<span class="method-title">outDegree</span> (line <span class="line-number">333</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Calculate the out degree of the node.</p>
<p class="description"><p>The outdegree for a node is the number of arcs exiting the node. For non directed graphs, the outdegree is always equal to the indegree.</p></p>
<ul class="tags">
<li><span class="field">return:</span> Out degree of the node</li>
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">integer</span>
<span class="method-name">
outDegree
</span>
()
</div>
</div>
<a name="methodsetData" id="setData"><!-- --></a>
<div class="evenrow">
<div class="method-header">
<span class="method-title">setData</span> (line <span class="line-number">134</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Node data setter</p>
<p class="description"><p>Each graph node can contain a reference to one variable. This is the setter for that reference.</p></p>
<ul class="tags">
<li><span class="field">return:</span> Data to store in node</li>
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">mixed</span>
<span class="method-name">
setData
</span>
(<span class="var-type">mixed</span> <span class="var-name">$data</span>)
</div>
</div>
<a name="methodsetGraph" id="setGraph"><!-- --></a>
<div class="oddrow">
<div class="method-header">
<span class="method-title">setGraph</span> (line <span class="line-number">104</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Node graph setter. This method should not be called directly. Use Graph::addNode instead.</p>
<ul class="tags">
<li><span class="field">access:</span> public</li>
<li><span class="field">see:</span> <a href="../Structures_Graph/Structures_Graph.html#methodaddNode">Structures_Graph::addNode()</a></li>
</ul>
<div class="method-signature">
<span class="method-result">void</span>
<span class="method-name">
setGraph
</span>
(<span class="var-type"><a href="../Structures_Graph/Structures_Graph.html">Structures_Graph</a></span> <span class="var-name">&$graph</span>)
</div>
<ul class="parameters">
<li>
<span class="var-type"><a href="../Structures_Graph/Structures_Graph.html">Structures_Graph</a></span>
<span class="var-name">&$graph</span><span class="var-description">: Set the graph for this node.</span> </li>
</ul>
</div>
<a name="methodsetMetadata" id="setMetadata"><!-- --></a>
<div class="evenrow">
<div class="method-header">
<span class="method-title">setMetadata</span> (line <span class="line-number">214</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Node metadata setter</p>
<p class="description"><p>Each graph node can contain multiple 'metadata' entries, each stored under a different key, as in an associative array or in a dictionary. This method stores data under the given key. If the key already exists, previously stored data is discarded.</p></p>
<ul class="tags">
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">void</span>
<span class="method-name">
setMetadata
</span>
(<span class="var-type">string</span> <span class="var-name">$key</span>, <span class="var-type">mixed</span> <span class="var-name">$data</span>)
</div>
<ul class="parameters">
<li>
<span class="var-type">string</span>
<span class="var-name">$key</span><span class="var-description">: Key</span> </li>
<li>
<span class="var-type">mixed</span>
<span class="var-name">$data</span><span class="var-description">: Data</span> </li>
</ul>
</div>
<a name="methodunsetMetadata" id="unsetMetadata"><!-- --></a>
<div class="oddrow">
<div class="method-header">
<span class="method-title">unsetMetadata</span> (line <span class="line-number">196</span>)
</div>
<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Delete metadata by key</p>
<p class="description"><p>Each graph node can contain multiple 'metadata' entries, each stored under a different key, as in an associative array or in a dictionary. This method removes any data that might be stored under the provided key. If the key does not exist, no error is thrown, so it is safe using this method without testing for key existence.</p></p>
<ul class="tags">
<li><span class="field">access:</span> public</li>
</ul>
<div class="method-signature">
<span class="method-result">void</span>
<span class="method-name">
unsetMetadata
</span>
(<span class="var-type">string</span> <span class="var-name">$key</span>)
</div>
<ul class="parameters">
<li>
<span class="var-type">string</span>
<span class="var-name">$key</span><span class="var-description">: Key</span> </li>
</ul>
</div>
</div>
</div>
<p class="notes" id="credit">
Documentation generated on Fri, 30 Jan 2004 16:37:29 +0000 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.2.3</a>
</p>
</div></body>
</html>
|