1 | <?php |
||
13 | class ITSF extends VersionedHeader |
||
14 | { |
||
15 | /** |
||
16 | * The "timestamp" (lower 32 bits of a 64-bit value representing the number of centiseconds since 1601-01-01 00:00:00 UTC, plus 42). |
||
17 | * |
||
18 | * @var int |
||
19 | */ |
||
20 | protected $timestamp; |
||
21 | |||
22 | /** |
||
23 | * The language of the OS at the time of compilation. |
||
24 | * |
||
25 | * @var Language |
||
26 | */ |
||
27 | protected $originalOSLanguage; |
||
28 | |||
29 | /** |
||
30 | * The directory GUID (it should be '{7C01FD10-7BAA-11D0-9E0C-00A0-C922-E6EC}'). |
||
31 | * |
||
32 | * @var string |
||
33 | */ |
||
34 | protected $directoryGUID; |
||
35 | |||
36 | /** |
||
37 | * The stream GUID (it should be '{7C01FD11-7BAA-11D0-9E0C-00A0-C922-E6EC}'). |
||
38 | * |
||
39 | * @var string |
||
40 | */ |
||
41 | protected $streamGUID; |
||
42 | |||
43 | /** |
||
44 | * The offset of the section (from the beginning of the file). |
||
45 | * |
||
46 | * @var int |
||
47 | */ |
||
48 | protected $sectionOffset; |
||
49 | |||
50 | /** |
||
51 | * The length of the section. |
||
52 | * |
||
53 | * @var int |
||
54 | */ |
||
55 | protected $sectionLength; |
||
56 | |||
57 | /** |
||
58 | * The offset of the directory (from the beginning of the file). |
||
59 | * |
||
60 | * @var int |
||
61 | */ |
||
62 | protected $directoryOffset; |
||
63 | |||
64 | /** |
||
65 | * The length of the directory. |
||
66 | * |
||
67 | * @var int |
||
68 | */ |
||
69 | protected $directoryLength; |
||
70 | |||
71 | /** |
||
72 | * The offset of the content (from the beginning of the file). |
||
73 | * |
||
74 | * @var int |
||
75 | */ |
||
76 | protected $contentOffset; |
||
77 | |||
78 | /** |
||
79 | * Initialize the instance. |
||
80 | * |
||
81 | * @param Reader $reader The reader that provides the data. |
||
82 | * |
||
83 | * @throws UnexpectedHeaderException Throws an UnexpectedHeaderException if the header signature is not valid. |
||
84 | * @throws Exception Throws an Exception in case of errors. |
||
85 | */ |
||
86 | 4 | public function __construct(Reader $reader) |
|
110 | |||
111 | /** |
||
112 | * Get the "timestamp" (lower 32 bits of a 64-bit value representing the number of centiseconds since 1601-01-01 00:00:00 UTC, plus 42). |
||
113 | * |
||
114 | * @return int |
||
115 | */ |
||
116 | public function getTimestamp() |
||
120 | |||
121 | /** |
||
122 | * Get the language of the OS at the time of compilation. |
||
123 | * |
||
124 | * @return Language |
||
125 | */ |
||
126 | public function getOriginalOSLanguage() |
||
130 | |||
131 | /** |
||
132 | * Get the directory GUID (it should be '{7C01FD10-7BAA-11D0-9E0C-00A0-C922-E6EC}'). |
||
133 | * |
||
134 | * @return string |
||
135 | */ |
||
136 | public function getDirectoryGUID() |
||
140 | |||
141 | /** |
||
142 | * Get the stream GUID (it should be '{7C01FD11-7BAA-11D0-9E0C-00A0-C922-E6EC}'). |
||
143 | * |
||
144 | * @return string |
||
145 | */ |
||
146 | public function getStreamGUID() |
||
150 | |||
151 | /** |
||
152 | * Get the offset of the section (from the beginning of the file). |
||
153 | * |
||
154 | * @return int |
||
155 | */ |
||
156 | 4 | public function getSectionOffset() |
|
160 | |||
161 | /** |
||
162 | * Get the length of section. |
||
163 | * |
||
164 | * @return int |
||
165 | */ |
||
166 | 4 | public function getSectionLength() |
|
170 | |||
171 | /** |
||
172 | * Get the offset of the directory (from the beginning of the file). |
||
173 | * |
||
174 | * @return int |
||
175 | */ |
||
176 | 4 | public function getDirectoryOffset() |
|
180 | |||
181 | /** |
||
182 | * Get the length of the directory. |
||
183 | * |
||
184 | * @return int |
||
185 | */ |
||
186 | 4 | public function getDirectoryLength() |
|
190 | |||
191 | /** |
||
192 | * Get the offset of the content (from the beginning of the file). |
||
193 | * |
||
194 | * @return int |
||
195 | */ |
||
196 | 4 | public function getContentOffset() |
|
200 | } |
||
201 |
Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.
The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.
This check looks for comments that seem to be mostly valid code and reports them.