@@ -231,6 +231,9 @@ discard block |
||
231 | 231 | return $this->loadIntoExisting($pFilename, $objPHPExcel); |
232 | 232 | } |
233 | 233 | |
234 | + /** |
|
235 | + * @param string $styleAttributeValue |
|
236 | + */ |
|
234 | 237 | protected static function identifyFixedStyleValue($styleList, &$styleAttributeValue) |
235 | 238 | { |
236 | 239 | $styleAttributeValue = strtolower($styleAttributeValue); |
@@ -786,6 +789,9 @@ discard block |
||
786 | 789 | } |
787 | 790 | |
788 | 791 | |
792 | + /** |
|
793 | + * @param string $charset |
|
794 | + */ |
|
789 | 795 | protected static function convertStringEncoding($string, $charset) |
790 | 796 | { |
791 | 797 | if ($charset != 'UTF-8') { |
@@ -115,10 +115,10 @@ discard block |
||
115 | 115 | { |
116 | 116 | // Check if file exists |
117 | 117 | if (!file_exists($pFilename)) { |
118 | - throw new Exception('Could not open '.$pFilename.' for reading! File does not exist.'); |
|
118 | + throw new Exception('Could not open ' . $pFilename . ' for reading! File does not exist.'); |
|
119 | 119 | } |
120 | 120 | if (!$this->canRead($pFilename)) { |
121 | - throw new Exception($pFilename.' is an Invalid Spreadsheet file.'); |
|
121 | + throw new Exception($pFilename . ' is an Invalid Spreadsheet file.'); |
|
122 | 122 | } |
123 | 123 | |
124 | 124 | $worksheetNames = []; |
@@ -150,7 +150,7 @@ discard block |
||
150 | 150 | { |
151 | 151 | // Check if file exists |
152 | 152 | if (!file_exists($pFilename)) { |
153 | - throw new Exception('Could not open '.$pFilename.' for reading! File does not exist.'); |
|
153 | + throw new Exception('Could not open ' . $pFilename . ' for reading! File does not exist.'); |
|
154 | 154 | } |
155 | 155 | |
156 | 156 | $worksheetInfo = []; |
@@ -327,11 +327,11 @@ discard block |
||
327 | 327 | |
328 | 328 | // Check if file exists |
329 | 329 | if (!file_exists($pFilename)) { |
330 | - throw new Exception('Could not open '.$pFilename.' for reading! File does not exist.'); |
|
330 | + throw new Exception('Could not open ' . $pFilename . ' for reading! File does not exist.'); |
|
331 | 331 | } |
332 | 332 | |
333 | 333 | if (!$this->canRead($pFilename)) { |
334 | - throw new Exception($pFilename.' is an Invalid Spreadsheet file.'); |
|
334 | + throw new Exception($pFilename . ' is an Invalid Spreadsheet file.'); |
|
335 | 335 | } |
336 | 336 | |
337 | 337 | $xml = simplexml_load_string( |
@@ -578,7 +578,7 @@ discard block |
||
578 | 578 | if (isset($cell_ss['Index'])) { |
579 | 579 | $columnID = \PhpOffice\PhpSpreadsheet\Cell::stringFromColumnIndex($cell_ss['Index'] - 1); |
580 | 580 | } |
581 | - $cellRange = $columnID.$rowID; |
|
581 | + $cellRange = $columnID . $rowID; |
|
582 | 582 | |
583 | 583 | if ($this->getReadFilter() !== null) { |
584 | 584 | if (!$this->getReadFilter()->readCell($columnID, $rowID, $worksheetName)) { |
@@ -596,7 +596,7 @@ discard block |
||
596 | 596 | if (isset($cell_ss['MergeDown'])) { |
597 | 597 | $rowTo = $rowTo + $cell_ss['MergeDown']; |
598 | 598 | } |
599 | - $cellRange .= ':'.$columnTo.$rowTo; |
|
599 | + $cellRange .= ':' . $columnTo . $rowTo; |
|
600 | 600 | $spreadsheet->getActiveSheet()->mergeCells($cellRange); |
601 | 601 | } |
602 | 602 | |
@@ -697,7 +697,7 @@ discard block |
||
697 | 697 | if ($columnReference{0} == '[') { |
698 | 698 | $columnReference = $columnNumber + trim($columnReference, '[]'); |
699 | 699 | } |
700 | - $A1CellReference = \PhpOffice\PhpSpreadsheet\Cell::stringFromColumnIndex($columnReference - 1).$rowReference; |
|
700 | + $A1CellReference = \PhpOffice\PhpSpreadsheet\Cell::stringFromColumnIndex($columnReference - 1) . $rowReference; |
|
701 | 701 | $value = substr_replace($value, $A1CellReference, $cellReference[0][1], strlen($cellReference[0][0])); |
702 | 702 | } |
703 | 703 | } |
@@ -708,9 +708,9 @@ discard block |
||
708 | 708 | $cellDataFormula = implode('"', $temp); |
709 | 709 | } |
710 | 710 | |
711 | - $spreadsheet->getActiveSheet()->getCell($columnID.$rowID)->setValueExplicit((($hasCalculatedValue) ? $cellDataFormula : $cellValue), $type); |
|
711 | + $spreadsheet->getActiveSheet()->getCell($columnID . $rowID)->setValueExplicit((($hasCalculatedValue) ? $cellDataFormula : $cellValue), $type); |
|
712 | 712 | if ($hasCalculatedValue) { |
713 | - $spreadsheet->getActiveSheet()->getCell($columnID.$rowID)->setCalculatedValue($cellValue); |
|
713 | + $spreadsheet->getActiveSheet()->getCell($columnID . $rowID)->setCalculatedValue($cellValue); |
|
714 | 714 | } |
715 | 715 | $cellIsSet = $rowHasData = true; |
716 | 716 | } |
@@ -723,14 +723,14 @@ discard block |
||
723 | 723 | } |
724 | 724 | $node = $cell->Comment->Data->asXML(); |
725 | 725 | $annotation = strip_tags($node); |
726 | - $spreadsheet->getActiveSheet()->getComment($columnID.$rowID)->setAuthor(self::convertStringEncoding($author, $this->charSet))->setText($this->parseRichText($annotation)); |
|
726 | + $spreadsheet->getActiveSheet()->getComment($columnID . $rowID)->setAuthor(self::convertStringEncoding($author, $this->charSet))->setText($this->parseRichText($annotation)); |
|
727 | 727 | } |
728 | 728 | |
729 | 729 | if (($cellIsSet) && (isset($cell_ss['StyleID']))) { |
730 | 730 | $style = (string) $cell_ss['StyleID']; |
731 | 731 | if ((isset($this->styles[$style])) && (!empty($this->styles[$style]))) { |
732 | - if (!$spreadsheet->getActiveSheet()->cellExists($columnID.$rowID)) { |
|
733 | - $spreadsheet->getActiveSheet()->getCell($columnID.$rowID)->setValue(null); |
|
732 | + if (!$spreadsheet->getActiveSheet()->cellExists($columnID . $rowID)) { |
|
733 | + $spreadsheet->getActiveSheet()->getCell($columnID . $rowID)->setValue(null); |
|
734 | 734 | } |
735 | 735 | $spreadsheet->getActiveSheet()->getStyle($cellRange)->applyFromArray($this->styles[$style]); |
736 | 736 | } |
@@ -816,7 +816,7 @@ discard block |
||
816 | 816 | * Return the eigenvector matrix |
817 | 817 | * |
818 | 818 | * @access public |
819 | - * @return V |
|
819 | + * @return Matrix |
|
820 | 820 | */ |
821 | 821 | public function getV() |
822 | 822 | { |
@@ -849,7 +849,7 @@ discard block |
||
849 | 849 | * Return the block diagonal eigenvalue matrix |
850 | 850 | * |
851 | 851 | * @access public |
852 | - * @return D |
|
852 | + * @return Matrix |
|
853 | 853 | */ |
854 | 854 | public function getD() |
855 | 855 | { |
@@ -436,7 +436,7 @@ discard block |
||
436 | 436 | * Return the left singular vectors |
437 | 437 | * |
438 | 438 | * @access public |
439 | - * @return U |
|
439 | + * @return Matrix |
|
440 | 440 | */ |
441 | 441 | public function getU() |
442 | 442 | { |
@@ -448,7 +448,7 @@ discard block |
||
448 | 448 | * Return the right singular vectors |
449 | 449 | * |
450 | 450 | * @access public |
451 | - * @return V |
|
451 | + * @return Matrix |
|
452 | 452 | */ |
453 | 453 | public function getV() |
454 | 454 | { |
@@ -472,7 +472,7 @@ discard block |
||
472 | 472 | * Return the diagonal matrix of singular values |
473 | 473 | * |
474 | 474 | * @access public |
475 | - * @return S |
|
475 | + * @return Matrix |
|
476 | 476 | */ |
477 | 477 | public function getS() |
478 | 478 | { |
@@ -81,7 +81,7 @@ |
||
81 | 81 | /** |
82 | 82 | * Return the Timezone transition for the specified timezone and timestamp |
83 | 83 | * |
84 | - * @param DateTimeZone $objTimezone The timezone for finding the transitions |
|
84 | + * @param \DateTimeZone $objTimezone The timezone for finding the transitions |
|
85 | 85 | * @param integer $timestamp PHP date/time value for finding the current transition |
86 | 86 | * @return array The current transition details |
87 | 87 | */ |
@@ -120,7 +120,7 @@ |
||
120 | 120 | { |
121 | 121 | if ($timezone !== null) { |
122 | 122 | if (!self::validateTimezone($timezone)) { |
123 | - throw new \PhpOffice\PhpSpreadsheet\Exception('Invalid timezone '.$timezone); |
|
123 | + throw new \PhpOffice\PhpSpreadsheet\Exception('Invalid timezone ' . $timezone); |
|
124 | 124 | } |
125 | 125 | } else { |
126 | 126 | $timezone = self::$timezone; |
@@ -23,7 +23,7 @@ |
||
23 | 23 | |
24 | 24 | define('POLYMORPHIC_ARGUMENT_EXCEPTION', -1); |
25 | 25 | $error['EN'][POLYMORPHIC_ARGUMENT_EXCEPTION] = "Invalid argument pattern for polymorphic function."; |
26 | -$error['FR'][POLYMORPHIC_ARGUMENT_EXCEPTION] = "Modèle inadmissible d'argument pour la fonction polymorphe.". |
|
26 | +$error['FR'][POLYMORPHIC_ARGUMENT_EXCEPTION] = "Modèle inadmissible d'argument pour la fonction polymorphe." . |
|
27 | 27 | $error['DE'][POLYMORPHIC_ARGUMENT_EXCEPTION] = "Unzulässiges Argumentmuster für polymorphe Funktion."; |
28 | 28 | |
29 | 29 | define('ARGUMENT_TYPE_EXCEPTION', -2); |
@@ -293,7 +293,7 @@ |
||
293 | 293 | $calcEngine = \PHPExcel\Calculation::getInstance($worksheet->getParent()); |
294 | 294 | $newDataValues = \PHPExcel\Calculation::unwrapResult( |
295 | 295 | $calcEngine->_calculateFormulaValue( |
296 | - '='.$this->dataSource, |
|
296 | + '=' . $this->dataSource, |
|
297 | 297 | null, |
298 | 298 | $worksheet->getCell('A1') |
299 | 299 | ) |
@@ -196,7 +196,7 @@ |
||
196 | 196 | foreach ($this->getCellList() as $coord) { |
197 | 197 | sscanf($coord, '%[A-Z]%d', $c, $r); |
198 | 198 | $row[$r] = $r; |
199 | - $col[$c] = strlen($c).$c; |
|
199 | + $col[$c] = strlen($c) . $c; |
|
200 | 200 | } |
201 | 201 | if (!empty($row)) { |
202 | 202 | // Determine highest column and row |
@@ -101,7 +101,7 @@ |
||
101 | 101 | /** |
102 | 102 | * Set Row Height |
103 | 103 | * |
104 | - * @param float $pValue |
|
104 | + * @param integer $pValue |
|
105 | 105 | * @return RowDimension |
106 | 106 | */ |
107 | 107 | public function setRowHeight($pValue = -1) |
@@ -101,7 +101,7 @@ |
||
101 | 101 | /** |
102 | 102 | * Set Row Height |
103 | 103 | * |
104 | - * @param float $pValue |
|
104 | + * @param integer $pValue |
|
105 | 105 | * @return RowDimension |
106 | 106 | */ |
107 | 107 | public function setRowHeight($pValue = -1) |
@@ -330,10 +330,10 @@ |
||
330 | 330 | } |
331 | 331 | |
332 | 332 | return md5( |
333 | - $this->getFillType(). |
|
334 | - $this->getRotation(). |
|
335 | - $this->getStartColor()->getHashCode(). |
|
336 | - $this->getEndColor()->getHashCode(). |
|
333 | + $this->getFillType() . |
|
334 | + $this->getRotation() . |
|
335 | + $this->getStartColor()->getHashCode() . |
|
336 | + $this->getEndColor()->getHashCode() . |
|
337 | 337 | __CLASS__ |
338 | 338 | ); |
339 | 339 | } |