@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | /** |
102 | 102 | * Implements support for fstat(). |
103 | 103 | * |
104 | - * @return boolean |
|
104 | + * @return string |
|
105 | 105 | */ |
106 | 106 | public function statName() |
107 | 107 | { |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | /** |
112 | 112 | * Implements support for fstat(). |
113 | 113 | * |
114 | - * @return boolean |
|
114 | + * @return string |
|
115 | 115 | */ |
116 | 116 | public function url_stat() // @codingStandardsIgnoreLine |
117 | 117 | { |
@@ -167,7 +167,7 @@ discard block |
||
167 | 167 | * |
168 | 168 | * @param int $offset byte offset |
169 | 169 | * @param int $whence SEEK_SET, SEEK_CUR or SEEK_END |
170 | - * @return bool |
|
170 | + * @return boolean|null |
|
171 | 171 | */ |
172 | 172 | public function stream_seek($offset, $whence) // @codingStandardsIgnoreLine |
173 | 173 | { |
@@ -174,26 +174,26 @@ |
||
174 | 174 | switch ($whence) { |
175 | 175 | case SEEK_SET: |
176 | 176 | if ($offset < strlen($this->data) && $offset >= 0) { |
177 | - $this->position = $offset; |
|
178 | - return true; |
|
177 | + $this->position = $offset; |
|
178 | + return true; |
|
179 | 179 | } else { |
180 | - return false; |
|
180 | + return false; |
|
181 | 181 | } |
182 | 182 | break; |
183 | 183 | case SEEK_CUR: |
184 | 184 | if ($offset >= 0) { |
185 | - $this->position += $offset; |
|
186 | - return true; |
|
185 | + $this->position += $offset; |
|
186 | + return true; |
|
187 | 187 | } else { |
188 | - return false; |
|
188 | + return false; |
|
189 | 189 | } |
190 | 190 | break; |
191 | 191 | case SEEK_END: |
192 | 192 | if (strlen($this->data) + $offset >= 0) { |
193 | - $this->position = strlen($this->data) + $offset; |
|
194 | - return true; |
|
193 | + $this->position = strlen($this->data) + $offset; |
|
194 | + return true; |
|
195 | 195 | } else { |
196 | - return false; |
|
196 | + return false; |
|
197 | 197 | } |
198 | 198 | break; |
199 | 199 | default: |
@@ -137,7 +137,7 @@ discard block |
||
137 | 137 | /** |
138 | 138 | * The workbook has macros ? |
139 | 139 | * |
140 | - * @return true if workbook has macros, false if not |
|
140 | + * @return boolean if workbook has macros, false if not |
|
141 | 141 | */ |
142 | 142 | public function hasMacros() |
143 | 143 | { |
@@ -178,7 +178,7 @@ discard block |
||
178 | 178 | /** |
179 | 179 | * Set the macros certificate |
180 | 180 | * |
181 | - * @param string|null $Certificate |
|
181 | + * @param string|null $certificate |
|
182 | 182 | */ |
183 | 183 | public function setMacrosCertificate($certificate = null) |
184 | 184 | { |
@@ -233,6 +233,7 @@ discard block |
||
233 | 233 | * retrieve ribbon XML Data |
234 | 234 | * |
235 | 235 | * return string|null|array |
236 | + * @return string |
|
236 | 237 | */ |
237 | 238 | public function getRibbonXMLData($what = 'all') //we need some constants here... |
238 | 239 | { |
@@ -308,7 +309,7 @@ discard block |
||
308 | 309 | /** |
309 | 310 | * This workbook have a custom UI ? |
310 | 311 | * |
311 | - * @return true|false |
|
312 | + * @return boolean |
|
312 | 313 | */ |
313 | 314 | public function hasRibbon() |
314 | 315 | { |
@@ -318,7 +319,7 @@ discard block |
||
318 | 319 | /** |
319 | 320 | * This workbook have additionnal object for the ribbon ? |
320 | 321 | * |
321 | - * @return true|false |
|
322 | + * @return boolean |
|
322 | 323 | */ |
323 | 324 | public function hasRibbonBinObjects() |
324 | 325 | { |
@@ -617,7 +618,7 @@ discard block |
||
617 | 618 | * Get index for sheet |
618 | 619 | * |
619 | 620 | * @param Worksheet $pSheet |
620 | - * @return Sheet index |
|
621 | + * @return integer index |
|
621 | 622 | * @throws Exception |
622 | 623 | */ |
623 | 624 | public function getIndex(Worksheet $pSheet) |
@@ -636,7 +637,7 @@ discard block |
||
636 | 637 | * |
637 | 638 | * @param string $sheetName Sheet name to modify index for |
638 | 639 | * @param int $newIndex New index for the sheet |
639 | - * @return New sheet index |
|
640 | + * @return integer sheet index |
|
640 | 641 | * @throws Exception |
641 | 642 | */ |
642 | 643 | public function setIndexByName($sheetName, $newIndex) |
@@ -778,7 +779,7 @@ discard block |
||
778 | 779 | * Add named range |
779 | 780 | * |
780 | 781 | * @param NamedRange $namedRange |
781 | - * @return PHPExcel |
|
782 | + * @return boolean |
|
782 | 783 | */ |
783 | 784 | public function addNamedRange(NamedRange $namedRange) |
784 | 785 | { |
@@ -823,7 +824,7 @@ discard block |
||
823 | 824 | * |
824 | 825 | * @param string $namedRange |
825 | 826 | * @param Worksheet|null $pSheet Scope: use null for global scope. |
826 | - * @return PHPExcel |
|
827 | + * @return Spreadsheet |
|
827 | 828 | */ |
828 | 829 | public function removeNamedRange($namedRange, Worksheet $pSheet = null) |
829 | 830 | { |
@@ -842,7 +843,7 @@ discard block |
||
842 | 843 | /** |
843 | 844 | * Get worksheet iterator |
844 | 845 | * |
845 | - * @return WorksheetIterator |
|
846 | + * @return Worksheet\Iterator |
|
846 | 847 | */ |
847 | 848 | public function getWorksheetIterator() |
848 | 849 | { |
@@ -852,7 +853,7 @@ discard block |
||
852 | 853 | /** |
853 | 854 | * Copy workbook (!= clone!) |
854 | 855 | * |
855 | - * @return PHPExcel |
|
856 | + * @return Spreadsheet |
|
856 | 857 | */ |
857 | 858 | public function copy() |
858 | 859 | { |
@@ -100,65 +100,65 @@ discard block |
||
100 | 100 | private $cellStyleXfCollection = array(); |
101 | 101 | |
102 | 102 | /** |
103 | - * hasMacros : this workbook have macros ? |
|
104 | - * |
|
105 | - * @var bool |
|
106 | - */ |
|
103 | + * hasMacros : this workbook have macros ? |
|
104 | + * |
|
105 | + * @var bool |
|
106 | + */ |
|
107 | 107 | private $hasMacros = false; |
108 | 108 | |
109 | 109 | /** |
110 | - * macrosCode : all macros code (the vbaProject.bin file, this include form, code, etc.), null if no macro |
|
111 | - * |
|
112 | - * @var binary |
|
113 | - */ |
|
110 | + * macrosCode : all macros code (the vbaProject.bin file, this include form, code, etc.), null if no macro |
|
111 | + * |
|
112 | + * @var binary |
|
113 | + */ |
|
114 | 114 | private $macrosCode; |
115 | 115 | /** |
116 | - * macrosCertificate : if macros are signed, contains vbaProjectSignature.bin file, null if not signed |
|
117 | - * |
|
118 | - * @var binary |
|
119 | - */ |
|
116 | + * macrosCertificate : if macros are signed, contains vbaProjectSignature.bin file, null if not signed |
|
117 | + * |
|
118 | + * @var binary |
|
119 | + */ |
|
120 | 120 | private $macrosCertificate; |
121 | 121 | |
122 | 122 | /** |
123 | - * ribbonXMLData : null if workbook is'nt Excel 2007 or not contain a customized UI |
|
124 | - * |
|
125 | - * @var null|string |
|
126 | - */ |
|
123 | + * ribbonXMLData : null if workbook is'nt Excel 2007 or not contain a customized UI |
|
124 | + * |
|
125 | + * @var null|string |
|
126 | + */ |
|
127 | 127 | private $ribbonXMLData; |
128 | 128 | |
129 | 129 | /** |
130 | - * ribbonBinObjects : null if workbook is'nt Excel 2007 or not contain embedded objects (picture(s)) for Ribbon Elements |
|
131 | - * ignored if $ribbonXMLData is null |
|
132 | - * |
|
133 | - * @var null|array |
|
134 | - */ |
|
130 | + * ribbonBinObjects : null if workbook is'nt Excel 2007 or not contain embedded objects (picture(s)) for Ribbon Elements |
|
131 | + * ignored if $ribbonXMLData is null |
|
132 | + * |
|
133 | + * @var null|array |
|
134 | + */ |
|
135 | 135 | private $ribbonBinObjects; |
136 | 136 | |
137 | 137 | /** |
138 | - * The workbook has macros ? |
|
139 | - * |
|
140 | - * @return true if workbook has macros, false if not |
|
141 | - */ |
|
138 | + * The workbook has macros ? |
|
139 | + * |
|
140 | + * @return true if workbook has macros, false if not |
|
141 | + */ |
|
142 | 142 | public function hasMacros() |
143 | 143 | { |
144 | 144 | return $this->hasMacros; |
145 | 145 | } |
146 | 146 | |
147 | 147 | /** |
148 | - * Define if a workbook has macros |
|
149 | - * |
|
150 | - * @param boolean $hasMacros true|false |
|
151 | - */ |
|
148 | + * Define if a workbook has macros |
|
149 | + * |
|
150 | + * @param boolean $hasMacros true|false |
|
151 | + */ |
|
152 | 152 | public function setHasMacros($hasMacros = false) |
153 | 153 | { |
154 | 154 | $this->hasMacros = (bool) $hasMacros; |
155 | 155 | } |
156 | 156 | |
157 | 157 | /** |
158 | - * Set the macros code |
|
159 | - * |
|
160 | - * @param string $macroCode string|null |
|
161 | - */ |
|
158 | + * Set the macros code |
|
159 | + * |
|
160 | + * @param string $macroCode string|null |
|
161 | + */ |
|
162 | 162 | public function setMacrosCode($macroCode = null) |
163 | 163 | { |
164 | 164 | $this->macrosCode = $macroCode; |
@@ -166,49 +166,49 @@ discard block |
||
166 | 166 | } |
167 | 167 | |
168 | 168 | /** |
169 | - * Return the macros code |
|
170 | - * |
|
171 | - * @return string|null |
|
172 | - */ |
|
169 | + * Return the macros code |
|
170 | + * |
|
171 | + * @return string|null |
|
172 | + */ |
|
173 | 173 | public function getMacrosCode() |
174 | 174 | { |
175 | 175 | return $this->macrosCode; |
176 | 176 | } |
177 | 177 | |
178 | 178 | /** |
179 | - * Set the macros certificate |
|
180 | - * |
|
181 | - * @param string|null $Certificate |
|
182 | - */ |
|
179 | + * Set the macros certificate |
|
180 | + * |
|
181 | + * @param string|null $Certificate |
|
182 | + */ |
|
183 | 183 | public function setMacrosCertificate($certificate = null) |
184 | 184 | { |
185 | 185 | $this->macrosCertificate = $certificate; |
186 | 186 | } |
187 | 187 | |
188 | 188 | /** |
189 | - * Is the project signed ? |
|
190 | - * |
|
191 | - * @return boolean true|false |
|
192 | - */ |
|
189 | + * Is the project signed ? |
|
190 | + * |
|
191 | + * @return boolean true|false |
|
192 | + */ |
|
193 | 193 | public function hasMacrosCertificate() |
194 | 194 | { |
195 | 195 | return !is_null($this->macrosCertificate); |
196 | 196 | } |
197 | 197 | |
198 | 198 | /** |
199 | - * Return the macros certificate |
|
200 | - * |
|
201 | - * @return string|null |
|
202 | - */ |
|
199 | + * Return the macros certificate |
|
200 | + * |
|
201 | + * @return string|null |
|
202 | + */ |
|
203 | 203 | public function getMacrosCertificate() |
204 | 204 | { |
205 | 205 | return $this->macrosCertificate; |
206 | 206 | } |
207 | 207 | |
208 | 208 | /** |
209 | - * Remove all macros, certificate from spreadsheet |
|
210 | - * |
|
211 | - */ |
|
209 | + * Remove all macros, certificate from spreadsheet |
|
210 | + * |
|
211 | + */ |
|
212 | 212 | public function discardMacros() |
213 | 213 | { |
214 | 214 | $this->hasMacros = false; |
@@ -217,9 +217,9 @@ discard block |
||
217 | 217 | } |
218 | 218 | |
219 | 219 | /** |
220 | - * set ribbon XML data |
|
221 | - * |
|
222 | - */ |
|
220 | + * set ribbon XML data |
|
221 | + * |
|
222 | + */ |
|
223 | 223 | public function setRibbonXMLData($target = null, $xmlData = null) |
224 | 224 | { |
225 | 225 | if (!is_null($target) && !is_null($xmlData)) { |
@@ -230,10 +230,10 @@ discard block |
||
230 | 230 | } |
231 | 231 | |
232 | 232 | /** |
233 | - * retrieve ribbon XML Data |
|
234 | - * |
|
235 | - * return string|null|array |
|
236 | - */ |
|
233 | + * retrieve ribbon XML Data |
|
234 | + * |
|
235 | + * return string|null|array |
|
236 | + */ |
|
237 | 237 | public function getRibbonXMLData($what = 'all') //we need some constants here... |
238 | 238 | { |
239 | 239 | $returnData = null; |
@@ -254,9 +254,9 @@ discard block |
||
254 | 254 | } |
255 | 255 | |
256 | 256 | /** |
257 | - * store binaries ribbon objects (pictures) |
|
258 | - * |
|
259 | - */ |
|
257 | + * store binaries ribbon objects (pictures) |
|
258 | + * |
|
259 | + */ |
|
260 | 260 | public function setRibbonBinObjects($BinObjectsNames = null, $BinObjectsData = null) |
261 | 261 | { |
262 | 262 | if (!is_null($BinObjectsNames) && !is_null($BinObjectsData)) { |
@@ -266,18 +266,18 @@ discard block |
||
266 | 266 | } |
267 | 267 | } |
268 | 268 | /** |
269 | - * return the extension of a filename. Internal use for a array_map callback (php<5.3 don't like lambda function) |
|
270 | - * |
|
271 | - */ |
|
269 | + * return the extension of a filename. Internal use for a array_map callback (php<5.3 don't like lambda function) |
|
270 | + * |
|
271 | + */ |
|
272 | 272 | private function getExtensionOnly($ThePath) |
273 | 273 | { |
274 | 274 | return pathinfo($ThePath, PATHINFO_EXTENSION); |
275 | 275 | } |
276 | 276 | |
277 | 277 | /** |
278 | - * retrieve Binaries Ribbon Objects |
|
279 | - * |
|
280 | - */ |
|
278 | + * retrieve Binaries Ribbon Objects |
|
279 | + * |
|
280 | + */ |
|
281 | 281 | public function getRibbonBinObjects($What = 'all') |
282 | 282 | { |
283 | 283 | $ReturnData = null; |
@@ -306,20 +306,20 @@ discard block |
||
306 | 306 | } |
307 | 307 | |
308 | 308 | /** |
309 | - * This workbook have a custom UI ? |
|
310 | - * |
|
311 | - * @return true|false |
|
312 | - */ |
|
309 | + * This workbook have a custom UI ? |
|
310 | + * |
|
311 | + * @return true|false |
|
312 | + */ |
|
313 | 313 | public function hasRibbon() |
314 | 314 | { |
315 | 315 | return !is_null($this->ribbonXMLData); |
316 | 316 | } |
317 | 317 | |
318 | 318 | /** |
319 | - * This workbook have additionnal object for the ribbon ? |
|
320 | - * |
|
321 | - * @return true|false |
|
322 | - */ |
|
319 | + * This workbook have additionnal object for the ribbon ? |
|
320 | + * |
|
321 | + * @return true|false |
|
322 | + */ |
|
323 | 323 | public function hasRibbonBinObjects() |
324 | 324 | { |
325 | 325 | return !is_null($this->ribbonBinObjects); |
@@ -354,9 +354,9 @@ discard block |
||
354 | 354 | return null; |
355 | 355 | } |
356 | 356 | |
357 | - /** |
|
358 | - * Create a new PHPExcel with one Worksheet |
|
359 | - */ |
|
357 | + /** |
|
358 | + * Create a new PHPExcel with one Worksheet |
|
359 | + */ |
|
360 | 360 | public function __construct() |
361 | 361 | { |
362 | 362 | $this->uniqueID = uniqid(); |
@@ -289,16 +289,16 @@ discard block |
||
289 | 289 | case 'names': |
290 | 290 | case 'data': |
291 | 291 | if (is_array($this->ribbonBinObjects) && array_key_exists($What, $this->ribbonBinObjects)) { |
292 | - $ReturnData=$this->ribbonBinObjects[$What]; |
|
292 | + $ReturnData = $this->ribbonBinObjects[$What]; |
|
293 | 293 | } |
294 | 294 | break; |
295 | 295 | case 'types': |
296 | 296 | if (is_array($this->ribbonBinObjects) && |
297 | 297 | array_key_exists('data', $this->ribbonBinObjects) && is_array($this->ribbonBinObjects['data'])) { |
298 | - $tmpTypes=array_keys($this->ribbonBinObjects['data']); |
|
298 | + $tmpTypes = array_keys($this->ribbonBinObjects['data']); |
|
299 | 299 | $ReturnData = array_unique(array_map(array($this, 'getExtensionOnly'), $tmpTypes)); |
300 | 300 | } else { |
301 | - $ReturnData=array(); // the caller want an array... not null if empty |
|
301 | + $ReturnData = array(); // the caller want an array... not null if empty |
|
302 | 302 | } |
303 | 303 | break; |
304 | 304 | } |
@@ -787,7 +787,7 @@ discard block |
||
787 | 787 | $this->namedRanges[$namedRange->getName()] = $namedRange; |
788 | 788 | } else { |
789 | 789 | // local scope |
790 | - $this->namedRanges[$namedRange->getScope()->getTitle().'!'.$namedRange->getName()] = $namedRange; |
|
790 | + $this->namedRanges[$namedRange->getScope()->getTitle() . '!' . $namedRange->getName()] = $namedRange; |
|
791 | 791 | } |
792 | 792 | return true; |
793 | 793 | } |
@@ -150,7 +150,7 @@ |
||
150 | 150 | /** |
151 | 151 | * Get parent. Only used for style supervisor |
152 | 152 | * |
153 | - * @return PHPExcel |
|
153 | + * @return Style |
|
154 | 154 | */ |
155 | 155 | public function getParent() |
156 | 156 | { |
@@ -618,7 +618,7 @@ |
||
618 | 618 | $this->numberFormat->getHashCode() . |
619 | 619 | $hashConditionals . |
620 | 620 | $this->protection->getHashCode() . |
621 | - ($this->quotePrefix ? 't' : 'f') . |
|
621 | + ($this->quotePrefix ? 't' : 'f') . |
|
622 | 622 | __CLASS__ |
623 | 623 | ); |
624 | 624 | } |
@@ -100,7 +100,7 @@ discard block |
||
100 | 100 | /** |
101 | 101 | * Get Condition type |
102 | 102 | * |
103 | - * @return string |
|
103 | + * @return integer |
|
104 | 104 | */ |
105 | 105 | public function getConditionType() |
106 | 106 | { |
@@ -122,7 +122,7 @@ discard block |
||
122 | 122 | /** |
123 | 123 | * Get Operator type |
124 | 124 | * |
125 | - * @return string |
|
125 | + * @return integer |
|
126 | 126 | */ |
127 | 127 | public function getOperatorType() |
128 | 128 | { |
@@ -250,8 +250,8 @@ |
||
250 | 250 | */ |
251 | 251 | public function setStyle(\PHPExcel\Style $pValue = null) |
252 | 252 | { |
253 | - $this->style = $pValue; |
|
254 | - return $this; |
|
253 | + $this->style = $pValue; |
|
254 | + return $this; |
|
255 | 255 | } |
256 | 256 | |
257 | 257 | /** |
@@ -329,7 +329,7 @@ discard block |
||
329 | 329 | /** |
330 | 330 | * Create a new worksheet |
331 | 331 | * |
332 | - * @param PHPExcel $pParent |
|
332 | + * @param PHPExcel $parent |
|
333 | 333 | * @param string $pTitle |
334 | 334 | */ |
335 | 335 | public function __construct(Spreadsheet $parent = null, $pTitle = 'Worksheet') |
@@ -586,7 +586,7 @@ discard block |
||
586 | 586 | * Get a chart by its index position |
587 | 587 | * |
588 | 588 | * @param string $index Chart index position |
589 | - * @return false|Chart |
|
589 | + * @return null|Chart |
|
590 | 590 | * @throws Exception |
591 | 591 | */ |
592 | 592 | public function getChartByIndex($index = null) |
@@ -768,7 +768,7 @@ discard block |
||
768 | 768 | /** |
769 | 769 | * Get parent |
770 | 770 | * |
771 | - * @return PHPExcel |
|
771 | + * @return Spreadsheet |
|
772 | 772 | */ |
773 | 773 | public function getParent() |
774 | 774 | { |
@@ -778,7 +778,7 @@ discard block |
||
778 | 778 | /** |
779 | 779 | * Re-bind parent |
780 | 780 | * |
781 | - * @param PHPExcel $parent |
|
781 | + * @param Spreadsheet $parent |
|
782 | 782 | * @return Worksheet |
783 | 783 | */ |
784 | 784 | public function rebindParent(Spreadsheet $parent) |
@@ -1078,7 +1078,7 @@ discard block |
||
1078 | 1078 | * Set a cell value |
1079 | 1079 | * |
1080 | 1080 | * @param string $pCoordinate Coordinate of the cell |
1081 | - * @param mixed $pValue Value of the cell |
|
1081 | + * @param integer $pValue Value of the cell |
|
1082 | 1082 | * @param bool $returnCell Return the worksheet (false, default) or the cell (true) |
1083 | 1083 | * @return Worksheet|Cell Depending on the last parameter being specified |
1084 | 1084 | */ |
@@ -1091,8 +1091,8 @@ discard block |
||
1091 | 1091 | /** |
1092 | 1092 | * Set a cell value by using numeric cell coordinates |
1093 | 1093 | * |
1094 | - * @param string $pColumn Numeric column coordinate of the cell (A = 0) |
|
1095 | - * @param string $pRow Numeric row coordinate of the cell |
|
1094 | + * @param integer $pColumn Numeric column coordinate of the cell (A = 0) |
|
1095 | + * @param integer $pRow Numeric row coordinate of the cell |
|
1096 | 1096 | * @param mixed $pValue Value of the cell |
1097 | 1097 | * @param bool $returnCell Return the worksheet (false, default) or the cell (true) |
1098 | 1098 | * @return Worksheet|Cell Depending on the last parameter being specified |
@@ -1122,8 +1122,8 @@ discard block |
||
1122 | 1122 | /** |
1123 | 1123 | * Set a cell value by using numeric cell coordinates |
1124 | 1124 | * |
1125 | - * @param string $pColumn Numeric column coordinate of the cell |
|
1126 | - * @param string $pRow Numeric row coordinate of the cell |
|
1125 | + * @param integer $pColumn Numeric column coordinate of the cell |
|
1126 | + * @param integer $pRow Numeric row coordinate of the cell |
|
1127 | 1127 | * @param mixed $pValue Value of the cell |
1128 | 1128 | * @param string $pDataType Explicit data type |
1129 | 1129 | * @param bool $returnCell Return the worksheet (false, default) or the cell (true) |
@@ -1183,8 +1183,8 @@ discard block |
||
1183 | 1183 | /** |
1184 | 1184 | * Get cell at a specific coordinate by using numeric cell coordinates |
1185 | 1185 | * |
1186 | - * @param string $pColumn Numeric column coordinate of the cell |
|
1187 | - * @param string $pRow Numeric row coordinate of the cell |
|
1186 | + * @param integer $pColumn Numeric column coordinate of the cell |
|
1187 | + * @param integer $pRow Numeric row coordinate of the cell |
|
1188 | 1188 | * @param boolean $createIfNotExists Flag indicating whether a new cell should be created if it doesn't |
1189 | 1189 | * already exist, or a null should be returned instead |
1190 | 1190 | * @return null|Cell Cell that was found/created or null |
@@ -1291,8 +1291,8 @@ discard block |
||
1291 | 1291 | /** |
1292 | 1292 | * Cell at a specific coordinate by using numeric cell coordinates exists? |
1293 | 1293 | * |
1294 | - * @param string $pColumn Numeric column coordinate of the cell |
|
1295 | - * @param string $pRow Numeric row coordinate of the cell |
|
1294 | + * @param integer $pColumn Numeric column coordinate of the cell |
|
1295 | + * @param integer $pRow Numeric row coordinate of the cell |
|
1296 | 1296 | * @return boolean |
1297 | 1297 | */ |
1298 | 1298 | public function cellExistsByColumnAndRow($pColumn = 0, $pRow = 1) |
@@ -1351,7 +1351,7 @@ discard block |
||
1351 | 1351 | /** |
1352 | 1352 | * Get column dimension at a specific column by using numeric cell coordinates |
1353 | 1353 | * |
1354 | - * @param string $pColumn Numeric column coordinate of the cell |
|
1354 | + * @param integer $pColumn Numeric column coordinate of the cell |
|
1355 | 1355 | * @return Worksheet\ColumnDimension |
1356 | 1356 | */ |
1357 | 1357 | public function getColumnDimensionByColumn($pColumn = 0) |
@@ -1472,7 +1472,7 @@ discard block |
||
1472 | 1472 | /** |
1473 | 1473 | * Set conditional styles |
1474 | 1474 | * |
1475 | - * @param $pCoordinate string E.g. 'A1' |
|
1475 | + * @param string $pCoordinate string E.g. 'A1' |
|
1476 | 1476 | * @param $pValue Style\Conditional[] |
1477 | 1477 | * @return Worksheet |
1478 | 1478 | */ |
@@ -1893,7 +1893,7 @@ discard block |
||
1893 | 1893 | /** |
1894 | 1894 | * Set AutoFilter |
1895 | 1895 | * |
1896 | - * @param Worksheet\AutoFilter|string $pValue |
|
1896 | + * @param string $pValue |
|
1897 | 1897 | * A simple string containing a Cell range like 'A1:E10' is permitted for backward compatibility |
1898 | 1898 | * @throws Exception |
1899 | 1899 | * @return Worksheet |
@@ -2903,7 +2903,7 @@ discard block |
||
2903 | 2903 | * Define the code name of the sheet |
2904 | 2904 | * |
2905 | 2905 | * @param null|string Same rule as Title minus space not allowed (but, like Excel, change silently space to underscore) |
2906 | - * @return objWorksheet |
|
2906 | + * @return Worksheet |
|
2907 | 2907 | * @throws Exception |
2908 | 2908 | */ |
2909 | 2909 | public function setCodeName($pValue = null) |
@@ -215,17 +215,17 @@ discard block |
||
215 | 215 | private $showGridlines = true; |
216 | 216 | |
217 | 217 | /** |
218 | - * Print gridlines? |
|
219 | - * |
|
220 | - * @var boolean |
|
221 | - */ |
|
218 | + * Print gridlines? |
|
219 | + * |
|
220 | + * @var boolean |
|
221 | + */ |
|
222 | 222 | private $printGridlines = false; |
223 | 223 | |
224 | 224 | /** |
225 | - * Show row and column headers? |
|
226 | - * |
|
227 | - * @var boolean |
|
228 | - */ |
|
225 | + * Show row and column headers? |
|
226 | + * |
|
227 | + * @var boolean |
|
228 | + */ |
|
229 | 229 | private $showRowColHeaders = true; |
230 | 230 | |
231 | 231 | /** |
@@ -320,10 +320,10 @@ discard block |
||
320 | 320 | private $hash; |
321 | 321 | |
322 | 322 | /** |
323 | - * CodeName |
|
324 | - * |
|
325 | - * @var string |
|
326 | - */ |
|
323 | + * CodeName |
|
324 | + * |
|
325 | + * @var string |
|
326 | + */ |
|
327 | 327 | private $codeName = null; |
328 | 328 | |
329 | 329 | /** |
@@ -390,7 +390,7 @@ discard block |
||
390 | 390 | $this->disconnectCells(); |
391 | 391 | } |
392 | 392 | |
393 | - /** |
|
393 | + /** |
|
394 | 394 | * Return the cache controller for the cell collection |
395 | 395 | * |
396 | 396 | * @return CachedObjectStorage_xxx |
@@ -439,7 +439,7 @@ discard block |
||
439 | 439 | return $pValue; |
440 | 440 | } |
441 | 441 | |
442 | - /** |
|
442 | + /** |
|
443 | 443 | * Check sheet title for valid Excel syntax |
444 | 444 | * |
445 | 445 | * @param string $pValue The string to check |
@@ -1248,7 +1248,7 @@ discard block |
||
1248 | 1248 | */ |
1249 | 1249 | public function cellExists($pCoordinate = 'A1') |
1250 | 1250 | { |
1251 | - // Worksheet reference? |
|
1251 | + // Worksheet reference? |
|
1252 | 1252 | if (strpos($pCoordinate, '!') !== false) { |
1253 | 1253 | $worksheetReference = Worksheet::extractSheetTitle($pCoordinate, true); |
1254 | 1254 | return $this->parent->getSheetByName($worksheetReference[0])->cellExists(strtoupper($worksheetReference[1])); |
@@ -2140,21 +2140,21 @@ discard block |
||
2140 | 2140 | } |
2141 | 2141 | |
2142 | 2142 | /** |
2143 | - * Print gridlines? |
|
2144 | - * |
|
2145 | - * @return boolean |
|
2146 | - */ |
|
2143 | + * Print gridlines? |
|
2144 | + * |
|
2145 | + * @return boolean |
|
2146 | + */ |
|
2147 | 2147 | public function getPrintGridlines() |
2148 | 2148 | { |
2149 | 2149 | return $this->printGridlines; |
2150 | 2150 | } |
2151 | 2151 | |
2152 | 2152 | /** |
2153 | - * Set print gridlines |
|
2154 | - * |
|
2155 | - * @param boolean $pValue Print gridlines (true/false) |
|
2156 | - * @return Worksheet |
|
2157 | - */ |
|
2153 | + * Set print gridlines |
|
2154 | + * |
|
2155 | + * @param boolean $pValue Print gridlines (true/false) |
|
2156 | + * @return Worksheet |
|
2157 | + */ |
|
2158 | 2158 | public function setPrintGridlines($pValue = false) |
2159 | 2159 | { |
2160 | 2160 | $this->printGridlines = $pValue; |
@@ -2162,21 +2162,21 @@ discard block |
||
2162 | 2162 | } |
2163 | 2163 | |
2164 | 2164 | /** |
2165 | - * Show row and column headers? |
|
2166 | - * |
|
2167 | - * @return boolean |
|
2168 | - */ |
|
2165 | + * Show row and column headers? |
|
2166 | + * |
|
2167 | + * @return boolean |
|
2168 | + */ |
|
2169 | 2169 | public function getShowRowColHeaders() |
2170 | 2170 | { |
2171 | 2171 | return $this->showRowColHeaders; |
2172 | 2172 | } |
2173 | 2173 | |
2174 | 2174 | /** |
2175 | - * Set show row and column headers |
|
2176 | - * |
|
2177 | - * @param boolean $pValue Show row and column headers (true/false) |
|
2178 | - * @return Worksheet |
|
2179 | - */ |
|
2175 | + * Set show row and column headers |
|
2176 | + * |
|
2177 | + * @param boolean $pValue Show row and column headers (true/false) |
|
2178 | + * @return Worksheet |
|
2179 | + */ |
|
2180 | 2180 | public function setShowRowColHeaders($pValue = false) |
2181 | 2181 | { |
2182 | 2182 | $this->showRowColHeaders = $pValue; |
@@ -2905,7 +2905,7 @@ discard block |
||
2905 | 2905 | * @param null|string Same rule as Title minus space not allowed (but, like Excel, change silently space to underscore) |
2906 | 2906 | * @return objWorksheet |
2907 | 2907 | * @throws Exception |
2908 | - */ |
|
2908 | + */ |
|
2909 | 2909 | public function setCodeName($pValue = null) |
2910 | 2910 | { |
2911 | 2911 | // Is this a 'rename' or not? |
@@ -2954,7 +2954,7 @@ discard block |
||
2954 | 2954 | * Return the code name of the sheet |
2955 | 2955 | * |
2956 | 2956 | * @return null|string |
2957 | - */ |
|
2957 | + */ |
|
2958 | 2958 | public function getCodeName() |
2959 | 2959 | { |
2960 | 2960 | return $this->codeName; |
@@ -2962,7 +2962,7 @@ discard block |
||
2962 | 2962 | /** |
2963 | 2963 | * Sheet has a code name ? |
2964 | 2964 | * @return boolean |
2965 | - */ |
|
2965 | + */ |
|
2966 | 2966 | public function hasCodeName() |
2967 | 2967 | { |
2968 | 2968 | return !(is_null($this->codeName)); |
@@ -426,8 +426,8 @@ discard block |
||
426 | 426 | } |
427 | 427 | // Some of the printable ASCII characters are invalid: * : / \ ? [ ] and first and last characters cannot be a "'" |
428 | 428 | if ((str_replace(self::$invalidCharacters, '', $pValue) !== $pValue) || |
429 | - (Shared\StringHelper::substring($pValue, -1, 1)=='\'') || |
|
430 | - (Shared\StringHelper::substring($pValue, 0, 1)=='\'')) { |
|
429 | + (Shared\StringHelper::substring($pValue, -1, 1) == '\'') || |
|
430 | + (Shared\StringHelper::substring($pValue, 0, 1) == '\'')) { |
|
431 | 431 | throw new Exception('Invalid character found in sheet code name'); |
432 | 432 | } |
433 | 433 | |
@@ -687,7 +687,7 @@ discard block |
||
687 | 687 | public function calculateWorksheetDimension() |
688 | 688 | { |
689 | 689 | // Return |
690 | - return 'A1' . ':' . $this->getHighestColumn() . $this->getHighestRow(); |
|
690 | + return 'A1' . ':' . $this->getHighestColumn() . $this->getHighestRow(); |
|
691 | 691 | } |
692 | 692 | |
693 | 693 | /** |
@@ -698,7 +698,7 @@ discard block |
||
698 | 698 | public function calculateWorksheetDataDimension() |
699 | 699 | { |
700 | 700 | // Return |
701 | - return 'A1' . ':' . $this->getHighestDataColumn() . $this->getHighestDataRow(); |
|
701 | + return 'A1' . ':' . $this->getHighestDataColumn() . $this->getHighestDataRow(); |
|
702 | 702 | } |
703 | 703 | |
704 | 704 | /** |
@@ -1158,8 +1158,8 @@ discard block |
||
1158 | 1158 | } |
1159 | 1159 | |
1160 | 1160 | // Named range? |
1161 | - if ((!preg_match('/^'.Calculation::CALCULATION_REGEXP_CELLREF.'$/i', $pCoordinate, $matches)) && |
|
1162 | - (preg_match('/^'.Calculation::CALCULATION_REGEXP_NAMEDRANGE.'$/i', $pCoordinate, $matches))) { |
|
1161 | + if ((!preg_match('/^' . Calculation::CALCULATION_REGEXP_CELLREF . '$/i', $pCoordinate, $matches)) && |
|
1162 | + (preg_match('/^' . Calculation::CALCULATION_REGEXP_NAMEDRANGE . '$/i', $pCoordinate, $matches))) { |
|
1163 | 1163 | $namedRange = NamedRange::resolveRange($pCoordinate, $this); |
1164 | 1164 | if ($namedRange !== null) { |
1165 | 1165 | $pCoordinate = $namedRange->getRange(); |
@@ -1255,8 +1255,8 @@ discard block |
||
1255 | 1255 | } |
1256 | 1256 | |
1257 | 1257 | // Named range? |
1258 | - if ((!preg_match('/^'.Calculation::CALCULATION_REGEXP_CELLREF.'$/i', $pCoordinate, $matches)) && |
|
1259 | - (preg_match('/^'.Calculation::CALCULATION_REGEXP_NAMEDRANGE.'$/i', $pCoordinate, $matches))) { |
|
1258 | + if ((!preg_match('/^' . Calculation::CALCULATION_REGEXP_CELLREF . '$/i', $pCoordinate, $matches)) && |
|
1259 | + (preg_match('/^' . Calculation::CALCULATION_REGEXP_NAMEDRANGE . '$/i', $pCoordinate, $matches))) { |
|
1260 | 1260 | $namedRange = NamedRange::resolveRange($pCoordinate, $this); |
1261 | 1261 | if ($namedRange !== null) { |
1262 | 1262 | $pCoordinate = $namedRange->getRange(); |
@@ -2360,7 +2360,7 @@ discard block |
||
2360 | 2360 | $pCoordinate = preg_replace('/^([0-9]+):([0-9]+)$/', 'A${1}:XFD${2}', $pCoordinate); |
2361 | 2361 | |
2362 | 2362 | if (strpos($pCoordinate, ':') !== false || strpos($pCoordinate, ',') !== false) { |
2363 | - list($first, ) = Cell::splitRange($pCoordinate); |
|
2363 | + list($first,) = Cell::splitRange($pCoordinate); |
|
2364 | 2364 | $this->activeCell = $first[0]; |
2365 | 2365 | } else { |
2366 | 2366 | $this->activeCell = $pCoordinate; |
@@ -2467,9 +2467,9 @@ discard block |
||
2467 | 2467 | $returnValue = array(); |
2468 | 2468 | // Identify the range that we need to extract from the worksheet |
2469 | 2469 | list($rangeStart, $rangeEnd) = Cell::rangeBoundaries($pRange); |
2470 | - $minCol = Cell::stringFromColumnIndex($rangeStart[0] -1); |
|
2470 | + $minCol = Cell::stringFromColumnIndex($rangeStart[0] - 1); |
|
2471 | 2471 | $minRow = $rangeStart[1]; |
2472 | - $maxCol = Cell::stringFromColumnIndex($rangeEnd[0] -1); |
|
2472 | + $maxCol = Cell::stringFromColumnIndex($rangeEnd[0] - 1); |
|
2473 | 2473 | $maxRow = $rangeEnd[1]; |
2474 | 2474 | |
2475 | 2475 | $maxCol++; |
@@ -2483,9 +2483,9 @@ discard block |
||
2483 | 2483 | $cRef = ($returnCellRef) ? $col : ++$c; |
2484 | 2484 | // Using getCell() will create a new cell if it doesn't already exist. We don't want that to happen |
2485 | 2485 | // so we test and retrieve directly against cellCollection |
2486 | - if ($this->cellCollection->isDataSet($col.$row)) { |
|
2486 | + if ($this->cellCollection->isDataSet($col . $row)) { |
|
2487 | 2487 | // Cell exists |
2488 | - $cell = $this->cellCollection->getCacheData($col.$row); |
|
2488 | + $cell = $this->cellCollection->getCacheData($col . $row); |
|
2489 | 2489 | if ($cell->getValue() !== null) { |
2490 | 2490 | if ($cell->getValue() instanceof RichText) { |
2491 | 2491 | $returnValue[$rRef][$cRef] = $cell->getValue()->getPlainText(); |
@@ -2542,7 +2542,7 @@ discard block |
||
2542 | 2542 | return $pWorkSheet->rangeToArray($pCellRange, $nullValue, $calculateFormulas, $formatData, $returnCellRef); |
2543 | 2543 | } |
2544 | 2544 | |
2545 | - throw new Exception('Named Range '.$pNamedRange.' does not exist.'); |
|
2545 | + throw new Exception('Named Range ' . $pNamedRange . ' does not exist.'); |
|
2546 | 2546 | } |
2547 | 2547 | |
2548 | 2548 | |
@@ -2565,7 +2565,7 @@ discard block |
||
2565 | 2565 | $maxCol = $this->getHighestColumn(); |
2566 | 2566 | $maxRow = $this->getHighestRow(); |
2567 | 2567 | // Return |
2568 | - return $this->rangeToArray('A1:'.$maxCol.$maxRow, $nullValue, $calculateFormulas, $formatData, $returnCellRef); |
|
2568 | + return $this->rangeToArray('A1:' . $maxCol . $maxRow, $nullValue, $calculateFormulas, $formatData, $returnCellRef); |
|
2569 | 2569 | } |
2570 | 2570 | |
2571 | 2571 | /** |
@@ -2815,7 +2815,7 @@ discard block |
||
2815 | 2815 | if ($rangeBoundaries[1][1] > $maxRow) { |
2816 | 2816 | $rangeBoundaries[1][1] = $maxRow; |
2817 | 2817 | } |
2818 | - $rangeSet = $rangeBoundaries[0][0].$rangeBoundaries[0][1].':'.$rangeBoundaries[1][0].$rangeBoundaries[1][1]; |
|
2818 | + $rangeSet = $rangeBoundaries[0][0] . $rangeBoundaries[0][1] . ':' . $rangeBoundaries[1][0] . $rangeBoundaries[1][1]; |
|
2819 | 2819 | } |
2820 | 2820 | unset($rangeSet); |
2821 | 2821 | $stRange = implode(' ', $rangeBlocks); |
@@ -2912,7 +2912,7 @@ discard block |
||
2912 | 2912 | if ($this->getCodeName() == $pValue) { |
2913 | 2913 | return $this; |
2914 | 2914 | } |
2915 | - $pValue = str_replace(' ', '_', $pValue);//Excel does this automatically without flinching, we are doing the same |
|
2915 | + $pValue = str_replace(' ', '_', $pValue); //Excel does this automatically without flinching, we are doing the same |
|
2916 | 2916 | // Syntax check |
2917 | 2917 | // throw an exception if not valid |
2918 | 2918 | self::checkSheetCodeName($pValue); |
@@ -2941,13 +2941,13 @@ discard block |
||
2941 | 2941 | } |
2942 | 2942 | } |
2943 | 2943 | |
2944 | - $pValue = $pValue . '_' . $i;// ok, we have a valid name |
|
2944 | + $pValue = $pValue . '_' . $i; // ok, we have a valid name |
|
2945 | 2945 | //codeName is'nt used in formula : no need to call for an update |
2946 | 2946 | //return $this->setTitle($altTitle, $updateFormulaCellReferences); |
2947 | 2947 | } |
2948 | 2948 | } |
2949 | 2949 | |
2950 | - $this->codeName=$pValue; |
|
2950 | + $this->codeName = $pValue; |
|
2951 | 2951 | return $this; |
2952 | 2952 | } |
2953 | 2953 | /** |
@@ -467,6 +467,7 @@ discard block |
||
467 | 467 | * |
468 | 468 | * @param string $dynamicRuleType |
469 | 469 | * @param AutoFilter\Column &$filterColumn |
470 | + * @param AutoFilter\Column $filterColumn |
|
470 | 471 | * @return mixed[] |
471 | 472 | */ |
472 | 473 | private function dynamicFilterDateRange($dynamicRuleType, &$filterColumn) |
@@ -571,6 +572,11 @@ discard block |
||
571 | 572 | return array('method' => 'filterTestInCustomDataSet', 'arguments' => array('filterRules' => $ruleValues, 'join' => AutoFilter\Column::AUTOFILTER_COLUMN_JOIN_AND)); |
572 | 573 | } |
573 | 574 | |
575 | + /** |
|
576 | + * @param integer $columnID |
|
577 | + * @param integer $startRow |
|
578 | + * @param string $ruleType |
|
579 | + */ |
|
574 | 580 | private function calculateTopTenValue($columnID, $startRow, $endRow, $ruleType, $ruleValue) |
575 | 581 | { |
576 | 582 | $range = $columnID.$startRow.':'.$columnID.$endRow; |
@@ -711,8 +711,8 @@ |
||
711 | 711 | ? AutoFilter\Column\Rule::AUTOFILTER_COLUMN_RULE_GREATERTHAN |
712 | 712 | : AutoFilter\Column\Rule::AUTOFILTER_COLUMN_RULE_LESSTHAN; |
713 | 713 | $ruleValues[] = array('operator' => $operator, |
714 | - 'value' => $average |
|
715 | - ); |
|
714 | + 'value' => $average |
|
715 | + ); |
|
716 | 716 | $columnFilterTests[$columnID] = array( |
717 | 717 | 'method' => 'filterTestInCustomDataSet', |
718 | 718 | 'arguments' => array('filterRules' => $ruleValues, 'join' => AutoFilter\Column::AUTOFILTER_COLUMN_JOIN_OR) |
@@ -408,7 +408,7 @@ discard block |
||
408 | 408 | } |
409 | 409 | } else { |
410 | 410 | // String values are always tested for equality, factoring in for wildcards (hence a regexp test) |
411 | - $retVal = preg_match('/^'.$rule['value'].'$/i', $cellValue); |
|
411 | + $retVal = preg_match('/^' . $rule['value'] . '$/i', $cellValue); |
|
412 | 412 | } |
413 | 413 | // If there are multiple conditions, then we need to test both using the appropriate join operator |
414 | 414 | switch ($join) { |
@@ -459,7 +459,7 @@ discard block |
||
459 | 459 | * @var array |
460 | 460 | */ |
461 | 461 | private static $fromReplace = array('\*', '\?', '~~', '~.*', '~.?'); |
462 | - private static $toReplace = array('.*', '.', '~', '\*', '\?'); |
|
462 | + private static $toReplace = array('.*', '.', '~', '\*', '\?'); |
|
463 | 463 | |
464 | 464 | |
465 | 465 | /** |
@@ -528,9 +528,9 @@ discard block |
||
528 | 528 | case AutoFilter\Column\Rule::AUTOFILTER_RULETYPE_DYNAMIC_NEXTQUARTER: |
529 | 529 | $thisMonth = date('m', $baseDate); |
530 | 530 | $thisQuarter = floor(--$thisMonth / 3); |
531 | - $maxVal = (int) \PHPExcel\Shared\Date::PHPtoExcel(gmmktime(0, 0, 0, date('t', $baseDate), (1+$thisQuarter)*3, date('Y', $baseDate))); |
|
531 | + $maxVal = (int) \PHPExcel\Shared\Date::PHPtoExcel(gmmktime(0, 0, 0, date('t', $baseDate), (1 + $thisQuarter) * 3, date('Y', $baseDate))); |
|
532 | 532 | ++$maxVal; |
533 | - $val = (int) \PHPExcel\Shared\Date::PHPToExcel(gmmktime(0, 0, 0, 1, 1+$thisQuarter*3, date('Y', $baseDate))); |
|
533 | + $val = (int) \PHPExcel\Shared\Date::PHPToExcel(gmmktime(0, 0, 0, 1, 1 + $thisQuarter * 3, date('Y', $baseDate))); |
|
534 | 534 | break; |
535 | 535 | case AutoFilter\Column\Rule::AUTOFILTER_RULETYPE_DYNAMIC_THISMONTH: |
536 | 536 | case AutoFilter\Column\Rule::AUTOFILTER_RULETYPE_DYNAMIC_LASTMONTH: |
@@ -573,7 +573,7 @@ discard block |
||
573 | 573 | |
574 | 574 | private function calculateTopTenValue($columnID, $startRow, $endRow, $ruleType, $ruleValue) |
575 | 575 | { |
576 | - $range = $columnID.$startRow.':'.$columnID.$endRow; |
|
576 | + $range = $columnID . $startRow . ':' . $columnID . $endRow; |
|
577 | 577 | $dataValues = \PHPExcel\Calculation\Functions::flattenArray($this->workSheet->rangeToArray($range, null, true, false)); |
578 | 578 | |
579 | 579 | $dataValues = array_filter($dataValues); |
@@ -704,7 +704,7 @@ discard block |
||
704 | 704 | ($dynamicRuleType == AutoFilter\Column\Rule::AUTOFILTER_RULETYPE_DYNAMIC_BELOWAVERAGE)) { |
705 | 705 | // Number (Average) based |
706 | 706 | // Calculate the average |
707 | - $averageFormula = '=AVERAGE('.$columnID.($rangeStart[1]+1).':'.$columnID.$rangeEnd[1].')'; |
|
707 | + $averageFormula = '=AVERAGE(' . $columnID . ($rangeStart[1] + 1) . ':' . $columnID . $rangeEnd[1] . ')'; |
|
708 | 708 | $average = \PHPExcel\Calculation::getInstance()->calculateFormula($averageFormula, null, $this->workSheet->getCell('A1')); |
709 | 709 | // Set above/below rule based on greaterThan or LessTan |
710 | 710 | $operator = ($dynamicRuleType === AutoFilter\Column\Rule::AUTOFILTER_RULETYPE_DYNAMIC_ABOVEAVERAGE) |
@@ -726,8 +726,8 @@ discard block |
||
726 | 726 | $ruleValues = array($period); |
727 | 727 | } else { |
728 | 728 | --$period; |
729 | - $periodEnd = (1+$period)*3; |
|
730 | - $periodStart = 1+$period*3; |
|
729 | + $periodEnd = (1 + $period) * 3; |
|
730 | + $periodStart = 1 + $period * 3; |
|
731 | 731 | $ruleValues = range($periodStart, $periodEnd); |
732 | 732 | } |
733 | 733 | $columnFilterTests[$columnID] = array( |
@@ -762,7 +762,7 @@ discard block |
||
762 | 762 | $ruleValue = 500; |
763 | 763 | } |
764 | 764 | |
765 | - $maxVal = $this->calculateTopTenValue($columnID, $rangeStart[1]+1, $rangeEnd[1], $toptenRuleType, $ruleValue); |
|
765 | + $maxVal = $this->calculateTopTenValue($columnID, $rangeStart[1] + 1, $rangeEnd[1], $toptenRuleType, $ruleValue); |
|
766 | 766 | |
767 | 767 | $operator = ($toptenRuleType == AutoFilter\Column\Rule::AUTOFILTER_COLUMN_RULE_TOPTEN_TOP) |
768 | 768 | ? AutoFilter\Column\Rule::AUTOFILTER_COLUMN_RULE_GREATERTHANOREQUAL |
@@ -781,12 +781,12 @@ discard block |
||
781 | 781 | // var_dump($columnFilterTests); |
782 | 782 | // |
783 | 783 | // Execute the column tests for each row in the autoFilter range to determine show/hide, |
784 | - for ($row = $rangeStart[1]+1; $row <= $rangeEnd[1]; ++$row) { |
|
784 | + for ($row = $rangeStart[1] + 1; $row <= $rangeEnd[1]; ++$row) { |
|
785 | 785 | // echo 'Testing Row = ', $row,PHP_EOL; |
786 | 786 | $result = true; |
787 | 787 | foreach ($columnFilterTests as $columnID => $columnFilterTest) { |
788 | 788 | // echo 'Testing cell ', $columnID.$row,PHP_EOL; |
789 | - $cellValue = $this->workSheet->getCell($columnID.$row)->getCalculatedValue(); |
|
789 | + $cellValue = $this->workSheet->getCell($columnID . $row)->getCalculatedValue(); |
|
790 | 790 | // echo 'Value is ', $cellValue,PHP_EOL; |
791 | 791 | // Execute the filter test |
792 | 792 | $result = $result && |
@@ -286,7 +286,7 @@ |
||
286 | 286 | * |
287 | 287 | * @param string $pRuleType |
288 | 288 | * @throws \PHPExcel\Exception |
289 | - * @return \PHPExcel\Worksheet\AutoFilter\Column |
|
289 | + * @return Rule |
|
290 | 290 | */ |
291 | 291 | public function setRuleType($pRuleType = self::AUTOFILTER_RULETYPE_FILTER) |
292 | 292 | { |
@@ -136,7 +136,7 @@ |
||
136 | 136 | /** |
137 | 137 | * Return the current cell in this worksheet column |
138 | 138 | * |
139 | - * @return Row |
|
139 | + * @return null|\PHPExcel\Cell |
|
140 | 140 | */ |
141 | 141 | public function current() |
142 | 142 | { |
@@ -69,7 +69,7 @@ discard block |
||
69 | 69 | /** |
70 | 70 | * Get ColumnIndex |
71 | 71 | * |
72 | - * @return string |
|
72 | + * @return integer |
|
73 | 73 | */ |
74 | 74 | public function getColumnIndex() |
75 | 75 | { |
@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | /** |
102 | 102 | * Set Width |
103 | 103 | * |
104 | - * @param double $pValue |
|
104 | + * @param integer $pValue |
|
105 | 105 | * @return ColumnDimension |
106 | 106 | */ |
107 | 107 | public function setWidth($pValue = -1) |