summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/support/lua2dox/examples/php/docs/html/animals_8php-source.html
blob: 0b09c6c0f9bdd57e989bc9e83a15880a95561716 (plain)
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
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>Sample Code (PHP): animals.php Source File</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
<h1>animals.php</h1><a href="animals_8php.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 &lt;?php
<a name="l00002"></a>00002 <span class="comment">/***** Copyright 2012 Simon Dales</span>
<a name="l00003"></a>00003 <span class="comment">**</span>
<a name="l00004"></a>00004 <span class="comment">** This work may be distributed and/or modified under the</span>
<a name="l00005"></a>00005 <span class="comment">** conditions of the LaTeX Project Public License, either version 1.3</span>
<a name="l00006"></a>00006 <span class="comment">** of this license or (at your option) any later version.</span>
<a name="l00007"></a>00007 <span class="comment">** The latest version of this license is in</span>
<a name="l00008"></a>00008 <span class="comment">**   http://www.latex-project.org/lppl.txt</span>
<a name="l00009"></a>00009 <span class="comment">**</span>
<a name="l00010"></a>00010 <span class="comment">** This work has the LPPL maintenance status `maintained'.</span>
<a name="l00011"></a>00011 <span class="comment">** </span>
<a name="l00012"></a>00012 <span class="comment">** The Current Maintainer of this work is Simon Dales.</span>
<a name="l00013"></a>00013 <span class="comment">*/</span>
<a name="l00014"></a>00014 
<a name="l00024"></a>00024 
<a name="l00025"></a><a class="code" href="animals_8php.html#8aed71372222cae35da78ac0f6c34c32">00025</a> function <a class="code" href="animals_8php.html#8aed71372222cae35da78ac0f6c34c32" title="write to stdout">TIO_write</a>($Str)
<a name="l00026"></a>00026 {
<a name="l00027"></a>00027   printf(<span class="stringliteral">'%s'</span>,$Str);
<a name="l00028"></a>00028 }
<a name="l00029"></a>00029 
<a name="l00031"></a><a class="code" href="animals_8php.html#1b5f1c2eef1479c9e7f6c1605c694bf9">00031</a> function <a class="code" href="animals_8php.html#1b5f1c2eef1479c9e7f6c1605c694bf9" title="writeln to stdout">TIO_writeln</a>($Str)
<a name="l00032"></a>00032 {
<a name="l00033"></a>00033   printf(<span class="stringliteral">"%s\n"</span>,$Str);
<a name="l00034"></a>00034 }
<a name="l00035"></a>00035 
<a name="l00037"></a><a class="code" href="classAnimal.html">00037</a> <span class="keyword">class </span><a class="code" href="classAnimal.html" title="a base class">Animal</a>{
<a name="l00038"></a><a class="code" href="classAnimal.html#1e726a49ec952443190ac62dad22353c">00038</a>   function <a class="code" href="classAnimal.html#1e726a49ec952443190ac62dad22353c">Animal</a>(){ 
<a name="l00039"></a>00039     $this-&gt;<a class="code" href="classAnimal.html#8e9da8131c7a28ddd3d2b3d59ba3275e">setKind</a>(<span class="stringliteral">'animal'</span>);
<a name="l00040"></a>00040     }
<a name="l00041"></a><a class="code" href="classAnimal.html#8e9da8131c7a28ddd3d2b3d59ba3275e">00041</a>   function <a class="code" href="classAnimal.html#8e9da8131c7a28ddd3d2b3d59ba3275e">setKind</a>($Kind){ 
<a name="l00042"></a>00042     $this-&gt;kind = $Kind;
<a name="l00043"></a>00043     }
<a name="l00044"></a><a class="code" href="classAnimal.html#4ec6768ff56f527202ab9c143a5ad4be">00044</a>   function <a class="code" href="classAnimal.html#4ec6768ff56f527202ab9c143a5ad4be">call</a>(){ 
<a name="l00045"></a>00045     $speigel = $this-&gt;speigel;
<a name="l00046"></a>00046     <span class="keywordflow">if</span> (isset($speigel))
<a name="l00047"></a>00047       $speigel = <span class="stringliteral">' says "'</span> . $speigel . <span class="charliteral">'"'</span>;
<a name="l00048"></a>00048     <span class="keywordflow">else</span>
<a name="l00049"></a>00049       $speigel = <span class="stringliteral">' &lt;undefined call&gt;'</span>;
<a name="l00050"></a>00050   
<a name="l00051"></a>00051     <a class="code" href="animals_8php.html#1b5f1c2eef1479c9e7f6c1605c694bf9" title="writeln to stdout">TIO_writeln</a>($this-&gt;kind . $speigel);
<a name="l00052"></a>00052     }
<a name="l00053"></a>00053 
<a name="l00054"></a>00054 };
<a name="l00055"></a>00055 
<a name="l00057"></a><a class="code" href="classBird.html">00057</a> <span class="keyword">class </span><a class="code" href="classBird.html" title="an abstract bird">Bird</a> <span class="keyword">extends</span> <a class="code" href="classAnimal.html" title="a base class">Animal</a>{
<a name="l00058"></a><a class="code" href="classBird.html#7c1b36856fe3a89d6098ec2b8a10ae8d">00058</a>   function <a class="code" href="classBird.html#7c1b36856fe3a89d6098ec2b8a10ae8d">Bird</a>(){ 
<a name="l00059"></a>00059     $this-&gt;<a class="code" href="classAnimal.html#8e9da8131c7a28ddd3d2b3d59ba3275e">setKind</a>(<span class="stringliteral">'bird'</span>);
<a name="l00060"></a>00060     }
<a name="l00061"></a>00061 };
<a name="l00062"></a>00062 
<a name="l00064"></a><a class="code" href="classPigeon.html">00064</a> <span class="keyword">class </span><a class="code" href="classPigeon.html" title="a subclassed bird">Pigeon</a> <span class="keyword">extends</span> <a class="code" href="classBird.html" title="an abstract bird">Bird</a>{
<a name="l00065"></a><a class="code" href="classPigeon.html#cccbf4642d6d786d5edd21adb73dec36">00065</a>   function <a class="code" href="classPigeon.html#cccbf4642d6d786d5edd21adb73dec36">Pigeon</a>(){ 
<a name="l00066"></a>00066     $this-&gt;<a class="code" href="classAnimal.html#8e9da8131c7a28ddd3d2b3d59ba3275e">setKind</a>(<span class="stringliteral">'pigeon'</span>);
<a name="l00067"></a>00067     $this-&gt;speigel = <span class="stringliteral">'oh my poor toe Betty'</span>;
<a name="l00068"></a>00068     }
<a name="l00069"></a>00069 };
<a name="l00070"></a>00070 
<a name="l00072"></a><a class="code" href="classRedKite.html">00072</a> <span class="keyword">class </span><a class="code" href="classRedKite.html" title="another subclassed bird">RedKite</a> <span class="keyword">extends</span> <a class="code" href="classBird.html" title="an abstract bird">Bird</a>{
<a name="l00073"></a><a class="code" href="classRedKite.html#acb11b00f12795cf8b2c21af75c1d0c1">00073</a>   function <a class="code" href="classRedKite.html#acb11b00f12795cf8b2c21af75c1d0c1">RedKite</a>(){ 
<a name="l00074"></a>00074     $this-&gt;<a class="code" href="classAnimal.html#8e9da8131c7a28ddd3d2b3d59ba3275e">setKind</a>(<span class="stringliteral">'red kite'</span>);
<a name="l00075"></a>00075     $this-&gt;speigel = <span class="stringliteral">'weee-ooo ee oo ee oo ee oo'</span>;
<a name="l00076"></a>00076     }
<a name="l00077"></a>00077 };
<a name="l00078"></a>00078 
<a name="l00080"></a><a class="code" href="classMammal.html">00080</a> <span class="keyword">class </span><a class="code" href="classMammal.html" title="a base mammal">Mammal</a> <span class="keyword">extends</span> <a class="code" href="classAnimal.html" title="a base class">Animal</a>{
<a name="l00081"></a>00081 };
<a name="l00082"></a>00082 
<a name="l00084"></a><a class="code" href="classCat.html">00084</a> <span class="keyword">class </span><a class="code" href="classCat.html" title="a subclassed mammal">Cat</a> <span class="keyword">extends</span> <a class="code" href="classMammal.html" title="a base mammal">Mammal</a>{
<a name="l00085"></a><a class="code" href="classCat.html#dff0d67c4d14c4eeeb35b8daa33ee442">00085</a>   function <a class="code" href="classCat.html#dff0d67c4d14c4eeeb35b8daa33ee442">Cat</a>(){ 
<a name="l00086"></a>00086     $this-&gt;<a class="code" href="classAnimal.html#8e9da8131c7a28ddd3d2b3d59ba3275e">setKind</a>(<span class="stringliteral">'cat'</span>);
<a name="l00087"></a>00087     $this-&gt;speigel = <span class="stringliteral">'meow'</span>;
<a name="l00088"></a>00088     }
<a name="l00089"></a>00089 };
<a name="l00090"></a>00090 
<a name="l00092"></a><a class="code" href="classDog.html">00092</a> <span class="keyword">class </span><a class="code" href="classDog.html" title="another subclassed mammal">Dog</a> <span class="keyword">extends</span> <a class="code" href="classMammal.html" title="a base mammal">Mammal</a>{
<a name="l00093"></a><a class="code" href="classDog.html#16e01978bb90b2989ee3da3e87071b1b">00093</a>   function <a class="code" href="classDog.html#16e01978bb90b2989ee3da3e87071b1b">Dog</a>(){ 
<a name="l00094"></a>00094     $this-&gt;<a class="code" href="classAnimal.html#8e9da8131c7a28ddd3d2b3d59ba3275e">setKind</a>(<span class="stringliteral">'dog'</span>);
<a name="l00095"></a>00095     $this-&gt;speigel = <span class="stringliteral">'woof'</span>;
<a name="l00096"></a>00096     }
<a name="l00097"></a>00097 };
<a name="l00098"></a>00098 
<a name="l00099"></a>00099 <span class="comment">//eof</span>
<a name="l00100"></a>00100 ?&gt;
</pre></div></div>
<hr size="1"><address style="text-align: right;"><small>Generated on Mon Jun 11 16:12:42 2012 for Sample Code (PHP) by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.6 </small></address>
</body>
</html>