1 | <?php |
||
5 | class COBAuthorBlock extends COBBlock { |
||
6 | |||
7 | /// @cond INTERNAL_DOCS |
||
8 | |||
9 | private $creationTime; |
||
10 | private $version; |
||
11 | private $revision; |
||
12 | private $authorName; |
||
13 | private $authorEmail; |
||
14 | private $authorURL; |
||
15 | private $authorComments; |
||
16 | |||
17 | /// @endcond |
||
18 | |||
19 | /// @brief Creates a new COBAuthorBlock |
||
20 | |||
21 | /** |
||
22 | * @param $authorName the name of the author of this COB |
||
23 | * @param $authorEmail the author's email address |
||
24 | * @param $authorURL The author's website address |
||
25 | * @param $authorComments Any comments the author had about this COB |
||
26 | * @param $creationTime the time this COB was compiled as a UNIX timestamp |
||
27 | * @param $version The version number of this COB (integer) |
||
28 | * @param $revision the COB's revision number (integer) |
||
29 | */ |
||
30 | public function COBAuthorBlock($authorName, $authorEmail, $authorURL, $authorComments, $creationTime, $version, $revision) { |
||
40 | |||
41 | /// @brief Supposedly compiles the block into binary. Throws an error to say it's not implemented. |
||
42 | /** @return string |
||
43 | */ |
||
44 | public function Compile() { |
||
48 | |||
49 | /// @brief Gets the name of the author |
||
50 | /** |
||
51 | * @return Author's name |
||
52 | */ |
||
53 | public function GetAuthorName() { |
||
56 | |||
57 | /// @brief Gets the author's email address |
||
58 | /** |
||
59 | * @return string |
||
60 | */ |
||
61 | public function GetAuthorEmail() { |
||
64 | |||
65 | /// @brief Gets the author's web address |
||
66 | /** |
||
67 | * @return string |
||
68 | */ |
||
69 | public function GetAuthorURL() { |
||
72 | |||
73 | /// @brief Gets comments from the author |
||
74 | /** |
||
75 | * @return string |
||
76 | */ |
||
77 | public function GetAuthorComments() { |
||
80 | |||
81 | /// @brief Gets the time this COB was created |
||
82 | /** |
||
83 | * @return A UNIX timestamp representing the time this COB was created. |
||
84 | */ |
||
85 | public function GetCreationTime() { |
||
88 | |||
89 | /// @brief Gets the COB's version number |
||
90 | /** |
||
91 | * @see GetRevision() |
||
92 | * @return An integer |
||
93 | */ |
||
94 | public function GetVersion() { |
||
97 | |||
98 | /// @brief Gets the COB's revision number |
||
99 | /** |
||
100 | * The revision number is less significant than the version |
||
101 | * number. |
||
102 | * @return An integer |
||
103 | */ |
||
104 | public function GetRevision() { |
||
107 | |||
108 | /// @cond INTERNAL_DOCS |
||
109 | |||
110 | /// @brief Creates the COBAuthorBlock from an IReader. |
||
111 | /** |
||
112 | * @param $reader The IReader, currently at the position of the author block |
||
113 | * @return COBAuthorBlock |
||
114 | */ |
||
115 | public static function CreateFromReader(IReader $reader) { |
||
129 | /// @endcond |
||
130 | } |
||
131 | ?> |
||
132 |
This check looks for a call to a parent method whose name is different than the method from which it is called.
Consider the following code:
The
getFirstName()
method in theSon
calls the wrong method in the parent class.