commit
1861412d60
24
.sami.php
24
.sami.php
|
@ -1,24 +0,0 @@
|
||||||
<?php
|
|
||||||
|
|
||||||
use Sami\RemoteRepository\GitHubRemoteRepository;
|
|
||||||
use Sami\Sami;
|
|
||||||
use Sami\Version\GitVersionCollection;
|
|
||||||
use Symfony\Component\Finder\Finder;
|
|
||||||
|
|
||||||
$iterator = Finder::create()
|
|
||||||
->files()
|
|
||||||
->name('*.php')
|
|
||||||
->in($dir = __DIR__ . '/src');
|
|
||||||
$versions = GitVersionCollection::create($dir)
|
|
||||||
->addFromTags(function ($version) {
|
|
||||||
return preg_match('~^\d+\.\d+\.\d+$~', $version);
|
|
||||||
})
|
|
||||||
->add('master');
|
|
||||||
|
|
||||||
return new Sami($iterator, [
|
|
||||||
'title' => 'PhpSpreadsheet',
|
|
||||||
'versions' => $versions,
|
|
||||||
'build_dir' => __DIR__ . '/build/%version%',
|
|
||||||
'cache_dir' => __DIR__ . '/cache/%version%',
|
|
||||||
'remote_repository' => new GitHubRemoteRepository('PHPOffice/PhpSpreadsheet', dirname($dir)),
|
|
||||||
]);
|
|
25
.travis.yml
25
.travis.yml
|
@ -2,14 +2,12 @@ language: php
|
||||||
dist: bionic
|
dist: bionic
|
||||||
|
|
||||||
php:
|
php:
|
||||||
- 7.1
|
|
||||||
- 7.2
|
- 7.2
|
||||||
- 7.3
|
- 7.3
|
||||||
- 7.4
|
- 7.4
|
||||||
|
|
||||||
cache:
|
cache:
|
||||||
directories:
|
directories:
|
||||||
- cache
|
|
||||||
- vendor
|
- vendor
|
||||||
- $HOME/.composer/cache
|
- $HOME/.composer/cache
|
||||||
|
|
||||||
|
@ -25,36 +23,29 @@ jobs:
|
||||||
include:
|
include:
|
||||||
|
|
||||||
- stage: Code style
|
- stage: Code style
|
||||||
php: 7.2
|
php: 7.4
|
||||||
script:
|
script:
|
||||||
- ./vendor/bin/php-cs-fixer fix --diff --verbose --dry-run
|
- ./vendor/bin/php-cs-fixer fix --diff --verbose --dry-run
|
||||||
- ./vendor/bin/phpcs --report-width=200 samples/ src/ tests/ --ignore=samples/Header.php --standard=PSR2 -n
|
- ./vendor/bin/phpcs --report-width=200 samples/ src/ tests/ --ignore=samples/Header.php --standard=PSR2 -n
|
||||||
|
|
||||||
- stage: Coverage
|
- stage: Coverage
|
||||||
php: 7.2
|
php: 7.4
|
||||||
script:
|
script:
|
||||||
- pecl install pcov
|
- pecl install pcov
|
||||||
- composer require pcov/clobber --dev
|
|
||||||
- ./vendor/bin/pcov clobber
|
|
||||||
- ./vendor/bin/phpunit --coverage-clover coverage-clover.xml
|
- ./vendor/bin/phpunit --coverage-clover coverage-clover.xml
|
||||||
after_script:
|
after_script:
|
||||||
- wget https://scrutinizer-ci.com/ocular.phar
|
- wget https://scrutinizer-ci.com/ocular.phar
|
||||||
- php ocular.phar code-coverage:upload --format=php-clover tests/coverage-clover.xml
|
- php ocular.phar code-coverage:upload --format=php-clover tests/coverage-clover.xml
|
||||||
|
|
||||||
- stage: API documentation
|
- stage: API documentations
|
||||||
php: 7.2
|
if: tag is present AND branch = master
|
||||||
|
php: 7.4
|
||||||
before_script:
|
before_script:
|
||||||
- curl -O https://get.sensiolabs.org/sami.phar
|
- curl -O https://github.com/phpDocumentor/phpDocumentor/releases/download/v3.0.0-rc/phpDocumentor.phar
|
||||||
script:
|
script:
|
||||||
- git fetch origin master:master
|
- php phpDocumentor.phar --directory src/ --target docs/api
|
||||||
- git fetch origin --tags
|
|
||||||
- php sami.phar update .sami.php
|
|
||||||
- echo '<html><head><meta http-equiv="Refresh" content="0; url=master/"></head><body><p>If you are not automatically redirected, please go to <a href="master/">the latest stable API documentation</a>.</p></body></html>' > build/index.html
|
|
||||||
deploy:
|
deploy:
|
||||||
provider: pages
|
provider: pages
|
||||||
skip-cleanup: true
|
skip-cleanup: true
|
||||||
local-dir: build
|
local-dir: docs/api
|
||||||
github-token: $GITHUB_TOKEN
|
github-token: $GITHUB_TOKEN
|
||||||
on:
|
|
||||||
all_branches: true
|
|
||||||
condition: $TRAVIS_BRANCH =~ ^master$
|
|
||||||
|
|
34
CHANGELOG.md
34
CHANGELOG.md
|
@ -7,10 +7,44 @@ and this project adheres to [Semantic Versioning](https://semver.org).
|
||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- Drop support for PHP 7.1, according to https://phpspreadsheet.readthedocs.io/en/latest/#php-version-support
|
||||||
|
|
||||||
|
## [1.12.0] - 2020-04-27
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
- Improved the ARABIC function to also handle short-hand roman numerals
|
||||||
|
- Added support for the FLOOR.MATH and FLOOR.PRECISE functions [#1351](https://github.com/PHPOffice/PhpSpreadsheet/pull/1351)
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- Fix ROUNDUP and ROUNDDOWN for floating-point rounding error [#1404](https://github.com/PHPOffice/PhpSpreadsheet/pull/1404)
|
||||||
|
- Fix ROUNDUP and ROUNDDOWN for negative number [#1417](https://github.com/PHPOffice/PhpSpreadsheet/pull/1417)
|
||||||
|
- Fix loading styles from vmlDrawings when containing whitespace [#1347](https://github.com/PHPOffice/PhpSpreadsheet/issues/1347)
|
||||||
|
- Fix incorrect behavior when removing last row [#1365](https://github.com/PHPOffice/PhpSpreadsheet/pull/1365)
|
||||||
|
- MATCH with a static array should return the position of the found value based on the values submitted [#1332](https://github.com/PHPOffice/PhpSpreadsheet/pull/1332)
|
||||||
|
- Fix Xlsx Reader's handling of undefined fill color [#1353](https://github.com/PHPOffice/PhpSpreadsheet/pull/1353)
|
||||||
|
|
||||||
|
## [1.11.0] - 2020-03-02
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
- Added support for the BASE function
|
||||||
|
- Added support for the ARABIC function
|
||||||
- Conditionals - Extend Support for (NOT)CONTAINSBLANKS [#1278](https://github.com/PHPOffice/PhpSpreadsheet/pull/1278)
|
- Conditionals - Extend Support for (NOT)CONTAINSBLANKS [#1278](https://github.com/PHPOffice/PhpSpreadsheet/pull/1278)
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
- Handle Error in Formula Processing Better for Xls [#1267](https://github.com/PHPOffice/PhpSpreadsheet/pull/1267)
|
- Handle Error in Formula Processing Better for Xls [#1267](https://github.com/PHPOffice/PhpSpreadsheet/pull/1267)
|
||||||
- Handle ConditionalStyle NumberFormat When Reading Xlsx File [#1296](https://github.com/PHPOffice/PhpSpreadsheet/pull/1296)
|
- Handle ConditionalStyle NumberFormat When Reading Xlsx File [#1296](https://github.com/PHPOffice/PhpSpreadsheet/pull/1296)
|
||||||
- Fix Xlsx Writer's handling of decimal commas [#1282](https://github.com/PHPOffice/PhpSpreadsheet/pull/1282)
|
- Fix Xlsx Writer's handling of decimal commas [#1282](https://github.com/PHPOffice/PhpSpreadsheet/pull/1282)
|
||||||
|
- Fix for issue by removing test code mistakenly left in [#1328](https://github.com/PHPOffice/PhpSpreadsheet/pull/1328)
|
||||||
|
- Fix for Xls writer wrong selected cells and active sheet [#1256](https://github.com/PHPOffice/PhpSpreadsheet/pull/1256)
|
||||||
|
- Fix active cell when freeze pane is used [#1323](https://github.com/PHPOffice/PhpSpreadsheet/pull/1323)
|
||||||
|
- Fix XLSX file loading with autofilter containing '$' [#1326](https://github.com/PHPOffice/PhpSpreadsheet/pull/1326)
|
||||||
|
- PHPDoc - Use `@return $this` for fluent methods [#1362](https://github.com/PHPOffice/PhpSpreadsheet/pull/1362)
|
||||||
|
|
||||||
## [1.10.1] - 2019-12-02
|
## [1.10.1] - 2019-12-02
|
||||||
|
|
||||||
|
|
|
@ -12,7 +12,7 @@ PhpSpreadsheet is a library written in pure PHP and providing a set of classes t
|
||||||
|
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
Read more about it, including install instructions, in the [official documentation](https://phpspreadsheet.readthedocs.io). Or check out the [API documentation](https://phpoffice.github.io/PhpSpreadsheet/master).
|
Read more about it, including install instructions, in the [official documentation](https://phpspreadsheet.readthedocs.io). Or check out the [API documentation](https://phpoffice.github.io/PhpSpreadsheet).
|
||||||
|
|
||||||
Please ask your support questions on [StackOverflow](https://stackoverflow.com/questions/tagged/phpspreadsheet), or have a quick chat on [Gitter](https://gitter.im/PHPOffice/PhpSpreadsheet).
|
Please ask your support questions on [StackOverflow](https://stackoverflow.com/questions/tagged/phpspreadsheet), or have a quick chat on [Gitter](https://gitter.im/PHPOffice/PhpSpreadsheet).
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
#!/usr/bin/env php
|
||||||
|
<?php
|
||||||
|
|
||||||
|
use PhpOffice\PhpSpreadsheet\Calculation\Calculation;
|
||||||
|
use PhpOffice\PhpSpreadsheet\DocumentGenerator;
|
||||||
|
|
||||||
|
require_once __DIR__ . '/../src/Bootstrap.php';
|
||||||
|
|
||||||
|
try {
|
||||||
|
$phpSpreadsheetFunctionsProperty = (new ReflectionClass(Calculation::class))->getProperty('phpSpreadsheetFunctions');
|
||||||
|
$phpSpreadsheetFunctionsProperty->setAccessible(true);
|
||||||
|
$phpSpreadsheetFunctions = $phpSpreadsheetFunctionsProperty->getValue();
|
||||||
|
ksort($phpSpreadsheetFunctions);
|
||||||
|
|
||||||
|
file_put_contents(__DIR__ . '/../docs/references/function-list-by-category.md',
|
||||||
|
DocumentGenerator::generateFunctionListByCategory($phpSpreadsheetFunctions)
|
||||||
|
);
|
||||||
|
file_put_contents(__DIR__ . '/../docs/references/function-list-by-name.md',
|
||||||
|
DocumentGenerator::generateFunctionListByName($phpSpreadsheetFunctions)
|
||||||
|
);
|
||||||
|
} catch (ReflectionException $e) {
|
||||||
|
fwrite(STDERR, (string)$e);
|
||||||
|
exit(1);
|
||||||
|
}
|
|
@ -35,11 +35,11 @@
|
||||||
"php-cs-fixer fix --ansi"
|
"php-cs-fixer fix --ansi"
|
||||||
],
|
],
|
||||||
"versions": [
|
"versions": [
|
||||||
"phpcs --report-width=200 samples/ src/ tests/ --ignore=samples/Header.php --standard=PHPCompatibility --runtime-set testVersion 7.1- -n"
|
"phpcs --report-width=200 samples/ src/ tests/ --ignore=samples/Header.php --standard=PHPCompatibility --runtime-set testVersion 7.2- -n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
"php": "^7.1",
|
"php": "^7.2",
|
||||||
"ext-ctype": "*",
|
"ext-ctype": "*",
|
||||||
"ext-dom": "*",
|
"ext-dom": "*",
|
||||||
"ext-gd": "*",
|
"ext-gd": "*",
|
||||||
|
@ -58,12 +58,12 @@
|
||||||
"psr/simple-cache": "^1.0"
|
"psr/simple-cache": "^1.0"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"dompdf/dompdf": "^0.8.3",
|
"dompdf/dompdf": "^0.8.5",
|
||||||
"friendsofphp/php-cs-fixer": "^2.16",
|
"friendsofphp/php-cs-fixer": "^2.16",
|
||||||
"jpgraph/jpgraph": "^4.0",
|
"jpgraph/jpgraph": "^4.0",
|
||||||
"mpdf/mpdf": "^8.0",
|
"mpdf/mpdf": "^8.0",
|
||||||
"phpcompatibility/php-compatibility": "^9.3",
|
"phpcompatibility/php-compatibility": "^9.3",
|
||||||
"phpunit/phpunit": "^7.5",
|
"phpunit/phpunit": "^8.5",
|
||||||
"squizlabs/php_codesniffer": "^3.5",
|
"squizlabs/php_codesniffer": "^3.5",
|
||||||
"tecnickcom/tcpdf": "^6.3"
|
"tecnickcom/tcpdf": "^6.3"
|
||||||
},
|
},
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -25,13 +25,14 @@ spreadsheet file formats, like Excel and LibreOffice Calc.
|
||||||
|
|
||||||
## Software requirements
|
## Software requirements
|
||||||
|
|
||||||
PHP version 7.1 or newer to develop using PhpSpreadsheet. Other requirements, such as PHP extensions, are enforced by
|
PHP version 7.2 or newer to develop using PhpSpreadsheet. Other requirements, such as PHP extensions, are enforced by
|
||||||
composer. See the `require` section of [the composer.json file](https://github.com/PHPOffice/PhpSpreadsheet/blob/master/composer.json)
|
composer. See the `require` section of [the composer.json file](https://github.com/PHPOffice/PhpSpreadsheet/blob/master/composer.json)
|
||||||
for details.
|
for details.
|
||||||
|
|
||||||
### PHP version support
|
### PHP version support
|
||||||
|
|
||||||
Support for PHP versions will only be maintained for a period of six months beyond the end-of-life of that PHP version
|
Support for PHP versions will only be maintained for a period of six months beyond the
|
||||||
|
[end of life of that PHP version](https://www.php.net/eol.php).
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
|
@ -89,7 +90,7 @@ architecture](./topics/architecture.md),
|
||||||
[accessing cells](./topics/accessing-cells.md) and
|
[accessing cells](./topics/accessing-cells.md) and
|
||||||
[reading and writing to files](./topics/reading-and-writing-to-file.md).
|
[reading and writing to files](./topics/reading-and-writing-to-file.md).
|
||||||
|
|
||||||
Or browse the [API documentation](https://phpoffice.github.io/PhpSpreadsheet/master).
|
Or browse the [API documentation](https://phpoffice.github.io/PhpSpreadsheet).
|
||||||
|
|
||||||
# Credits
|
# Credits
|
||||||
|
|
||||||
|
|
|
@ -69,12 +69,12 @@ BESSELK | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BESSELK
|
||||||
BESSELY | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BESSELY
|
BESSELY | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BESSELY
|
||||||
BIN2DEC | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BINTODEC
|
BIN2DEC | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BINTODEC
|
||||||
BIN2HEX | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BINTOHEX
|
BIN2HEX | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BINTOHEX
|
||||||
BIN2OCT | \PhpOffice\PhpSpreadsheet\Calculation\Engineeri
|
BIN2OCT | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BINTOOCT
|
||||||
BITAND | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITAND
|
BITAND | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITAND
|
||||||
BITLSHIFT | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITLSHIFT
|
BITLSHIFT | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITLSHIFT
|
||||||
BITOR | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITOR
|
BITOR | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITOR
|
||||||
BITRSHIFT | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITRSHIFT
|
BITRSHIFT | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITRSHIFT
|
||||||
BITXOR | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITXOR
|
BITXOR | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITOR
|
||||||
COMPLEX | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::COMPLEX
|
COMPLEX | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::COMPLEX
|
||||||
CONVERT | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::CONVERTUOM
|
CONVERT | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::CONVERTUOM
|
||||||
DEC2BIN | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::DECTOBIN
|
DEC2BIN | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::DECTOBIN
|
||||||
|
@ -184,21 +184,21 @@ YIELDMAT | \PhpOffice\PhpSpreadsheet\Calculation\Financial::YIELDMAT
|
||||||
Excel Function | PhpSpreadsheet Function
|
Excel Function | PhpSpreadsheet Function
|
||||||
--------------------|-------------------------------------------
|
--------------------|-------------------------------------------
|
||||||
CELL | **Not yet Implemented**
|
CELL | **Not yet Implemented**
|
||||||
ERROR.TYPE | \PhpOffice\PhpSpreadsheet\Calculation\Functions::ERROR_TYPE
|
ERROR.TYPE | \PhpOffice\PhpSpreadsheet\Calculation\Functions::errorType
|
||||||
INFO | **Not yet Implemented**
|
INFO | **Not yet Implemented**
|
||||||
ISBLANK | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_BLANK
|
ISBLANK | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isBlank
|
||||||
ISERR | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_ERR
|
ISERR | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isErr
|
||||||
ISERROR | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_ERROR
|
ISERROR | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isError
|
||||||
ISEVEN | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_EVEN
|
ISEVEN | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isEven
|
||||||
ISFORMULA | \PhpOffice\PhpSpreadsheet\Calculation\Functions::ISFORMULA
|
ISFORMULA | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isFormula
|
||||||
ISLOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_LOGICAL
|
ISLOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isLogical
|
||||||
ISNA | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_NA
|
ISNA | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isNa
|
||||||
ISNONTEXT | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_NONTEXT
|
ISNONTEXT | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isNonText
|
||||||
ISNUMBER | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_NUMBER
|
ISNUMBER | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isNumber
|
||||||
ISODD | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_ODD
|
ISODD | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isOdd
|
||||||
ISREF | **Not yet Implemented**
|
ISREF | **Not yet Implemented**
|
||||||
ISTEXT | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_TEXT
|
ISTEXT | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isText
|
||||||
N | \PhpOffice\PhpSpreadsheet\Calculation\Functions::N
|
N | \PhpOffice\PhpSpreadsheet\Calculation\Functions::n
|
||||||
NA | \PhpOffice\PhpSpreadsheet\Calculation\Functions::NA
|
NA | \PhpOffice\PhpSpreadsheet\Calculation\Functions::NA
|
||||||
TYPE | \PhpOffice\PhpSpreadsheet\Calculation\Functions::TYPE
|
TYPE | \PhpOffice\PhpSpreadsheet\Calculation\Functions::TYPE
|
||||||
|
|
||||||
|
@ -208,11 +208,13 @@ Excel Function | PhpSpreadsheet Function
|
||||||
--------------------|-------------------------------------------
|
--------------------|-------------------------------------------
|
||||||
AND | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalAnd
|
AND | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalAnd
|
||||||
FALSE | \PhpOffice\PhpSpreadsheet\Calculation\Logical::FALSE
|
FALSE | \PhpOffice\PhpSpreadsheet\Calculation\Logical::FALSE
|
||||||
IF | \PhpOffice\PhpSpreadsheet\Calculation\Logical::STATEMENT_IF
|
IF | \PhpOffice\PhpSpreadsheet\Calculation\Logical::statementIf
|
||||||
IFERROR | \PhpOffice\PhpSpreadsheet\Calculation\Logical::IFERROR
|
IFERROR | \PhpOffice\PhpSpreadsheet\Calculation\Logical::IFERROR
|
||||||
IFNA | \PhpOffice\PhpSpreadsheet\Calculation\Logical::IFNA
|
IFNA | \PhpOffice\PhpSpreadsheet\Calculation\Logical::IFNA
|
||||||
|
IFS | **Not yet Implemented**
|
||||||
NOT | \PhpOffice\PhpSpreadsheet\Calculation\Logical::NOT
|
NOT | \PhpOffice\PhpSpreadsheet\Calculation\Logical::NOT
|
||||||
OR | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalOr
|
OR | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalOr
|
||||||
|
SWITCH | \PhpOffice\PhpSpreadsheet\Calculation\Logical::statementSwitch
|
||||||
TRUE | \PhpOffice\PhpSpreadsheet\Calculation\Logical::TRUE
|
TRUE | \PhpOffice\PhpSpreadsheet\Calculation\Logical::TRUE
|
||||||
XOR | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalXor
|
XOR | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalXor
|
||||||
|
|
||||||
|
@ -220,7 +222,7 @@ XOR | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalXor
|
||||||
|
|
||||||
Excel Function | PhpSpreadsheet Function
|
Excel Function | PhpSpreadsheet Function
|
||||||
--------------------|-------------------------------------------
|
--------------------|-------------------------------------------
|
||||||
ADDRESS | \PhpOffice\PhpSpreadsheet\Calculation\LookupRef::CELL_ADDRESS
|
ADDRESS | \PhpOffice\PhpSpreadsheet\Calculation\LookupRef::cellAddress
|
||||||
AREAS | **Not yet Implemented**
|
AREAS | **Not yet Implemented**
|
||||||
CHOOSE | \PhpOffice\PhpSpreadsheet\Calculation\LookupRef::CHOOSE
|
CHOOSE | \PhpOffice\PhpSpreadsheet\Calculation\LookupRef::CHOOSE
|
||||||
COLUMN | \PhpOffice\PhpSpreadsheet\Calculation\LookupRef::COLUMN
|
COLUMN | \PhpOffice\PhpSpreadsheet\Calculation\LookupRef::COLUMN
|
||||||
|
@ -249,11 +251,13 @@ ACOS | acos
|
||||||
ACOSH | acosh
|
ACOSH | acosh
|
||||||
ACOT | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ACOT
|
ACOT | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ACOT
|
||||||
ACOTH | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ACOTH
|
ACOTH | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ACOTH
|
||||||
|
ARABIC | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ARABIC
|
||||||
ASIN | asin
|
ASIN | asin
|
||||||
ASINH | asinh
|
ASINH | asinh
|
||||||
ATAN | atan
|
ATAN | atan
|
||||||
ATAN2 | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::REVERSE_ATAN2
|
ATAN2 | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ATAN2
|
||||||
ATANH | atanh
|
ATANH | atanh
|
||||||
|
BASE | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::BASE
|
||||||
CEILING | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::CEILING
|
CEILING | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::CEILING
|
||||||
COMBIN | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::COMBIN
|
COMBIN | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::COMBIN
|
||||||
COS | cos
|
COS | cos
|
||||||
|
@ -272,7 +276,7 @@ GCD | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::GCD
|
||||||
INT | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::INT
|
INT | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::INT
|
||||||
LCM | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::LCM
|
LCM | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::LCM
|
||||||
LN | log
|
LN | log
|
||||||
LOG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::LOG_BASE
|
LOG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::logBase
|
||||||
LOG10 | log10
|
LOG10 | log10
|
||||||
MDETERM | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::MDETERM
|
MDETERM | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::MDETERM
|
||||||
MINVERSE | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::MINVERSE
|
MINVERSE | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::MINVERSE
|
||||||
|
@ -389,8 +393,8 @@ SLOPE | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::SLOPE
|
||||||
SMALL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::SMALL
|
SMALL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::SMALL
|
||||||
STANDARDIZE | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STANDARDIZE
|
STANDARDIZE | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STANDARDIZE
|
||||||
STDEV | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEV
|
STDEV | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEV
|
||||||
STDEV.S | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEV
|
|
||||||
STDEV.P | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVP
|
STDEV.P | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVP
|
||||||
|
STDEV.S | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEV
|
||||||
STDEVA | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVA
|
STDEVA | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVA
|
||||||
STDEVP | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVP
|
STDEVP | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVP
|
||||||
STDEVPA | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVPA
|
STDEVPA | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVPA
|
||||||
|
|
|
@ -11,16 +11,17 @@ ACOS | CATEGORY_MATH_AND_TRIG | acos
|
||||||
ACOSH | CATEGORY_MATH_AND_TRIG | acosh
|
ACOSH | CATEGORY_MATH_AND_TRIG | acosh
|
||||||
ACOT | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ACOT
|
ACOT | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ACOT
|
||||||
ACOTH | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ACOTH
|
ACOTH | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ACOTH
|
||||||
ADDRESS | CATEGORY_LOOKUP_AND_REFERENCE | \PhpOffice\PhpSpreadsheet\Calculation\LookupRef::CELL_ADDRESS
|
ADDRESS | CATEGORY_LOOKUP_AND_REFERENCE | \PhpOffice\PhpSpreadsheet\Calculation\LookupRef::cellAddress
|
||||||
AMORDEGRC | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::AMORDEGRC
|
AMORDEGRC | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::AMORDEGRC
|
||||||
AMORLINC | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::AMORLINC
|
AMORLINC | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::AMORLINC
|
||||||
AND | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalAnd
|
AND | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalAnd
|
||||||
|
ARABIC | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ARABIC
|
||||||
AREAS | CATEGORY_LOOKUP_AND_REFERENCE | **Not yet Implemented**
|
AREAS | CATEGORY_LOOKUP_AND_REFERENCE | **Not yet Implemented**
|
||||||
ASC | CATEGORY_TEXT_AND_DATA | **Not yet Implemented**
|
ASC | CATEGORY_TEXT_AND_DATA | **Not yet Implemented**
|
||||||
ASIN | CATEGORY_MATH_AND_TRIG | asin
|
ASIN | CATEGORY_MATH_AND_TRIG | asin
|
||||||
ASINH | CATEGORY_MATH_AND_TRIG | asinh
|
ASINH | CATEGORY_MATH_AND_TRIG | asinh
|
||||||
ATAN | CATEGORY_MATH_AND_TRIG | atan
|
ATAN | CATEGORY_MATH_AND_TRIG | atan
|
||||||
ATAN2 | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::REVERSE_ATAN2
|
ATAN2 | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::ATAN2
|
||||||
ATANH | CATEGORY_MATH_AND_TRIG | atanh
|
ATANH | CATEGORY_MATH_AND_TRIG | atanh
|
||||||
AVEDEV | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::AVEDEV
|
AVEDEV | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::AVEDEV
|
||||||
AVERAGE | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::AVERAGE
|
AVERAGE | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::AVERAGE
|
||||||
|
@ -33,6 +34,7 @@ AVERAGEIFS | CATEGORY_STATISTICAL | **Not yet Implemented**
|
||||||
Excel Function | Category | PhpSpreadsheet Function
|
Excel Function | Category | PhpSpreadsheet Function
|
||||||
--------------------|--------------------------------|-------------------------------------------
|
--------------------|--------------------------------|-------------------------------------------
|
||||||
BAHTTEXT | CATEGORY_TEXT_AND_DATA | **Not yet Implemented**
|
BAHTTEXT | CATEGORY_TEXT_AND_DATA | **Not yet Implemented**
|
||||||
|
BASE | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::BASE
|
||||||
BESSELI | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BESSELI
|
BESSELI | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BESSELI
|
||||||
BESSELJ | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BESSELJ
|
BESSELJ | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BESSELJ
|
||||||
BESSELK | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BESSELK
|
BESSELK | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BESSELK
|
||||||
|
@ -47,7 +49,7 @@ BITAND | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet
|
||||||
BITLSHIFT | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITLSHIFT
|
BITLSHIFT | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITLSHIFT
|
||||||
BITOR | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITOR
|
BITOR | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITOR
|
||||||
BITRSHIFT | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITRSHIFT
|
BITRSHIFT | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITRSHIFT
|
||||||
BITXOR | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITXOR
|
BITXOR | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::BITOR
|
||||||
|
|
||||||
## C
|
## C
|
||||||
|
|
||||||
|
@ -147,7 +149,7 @@ ERF | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet
|
||||||
ERF.PRECISE | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::ERFPRECISE
|
ERF.PRECISE | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::ERFPRECISE
|
||||||
ERFC | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::ERFC
|
ERFC | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::ERFC
|
||||||
ERFC.PRECISE | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::ERFC
|
ERFC.PRECISE | CATEGORY_ENGINEERING | \PhpOffice\PhpSpreadsheet\Calculation\Engineering::ERFC
|
||||||
ERROR.TYPE | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::ERROR_TYPE
|
ERROR.TYPE | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::errorType
|
||||||
EVEN | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::EVEN
|
EVEN | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::EVEN
|
||||||
EXACT | CATEGORY_TEXT_AND_DATA | \PhpOffice\PhpSpreadsheet\Calculation\TextData::EXACT
|
EXACT | CATEGORY_TEXT_AND_DATA | \PhpOffice\PhpSpreadsheet\Calculation\TextData::EXACT
|
||||||
EXP | CATEGORY_MATH_AND_TRIG | exp
|
EXP | CATEGORY_MATH_AND_TRIG | exp
|
||||||
|
@ -205,7 +207,7 @@ HYPGEOMDIST | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet
|
||||||
|
|
||||||
Excel Function | Category | PhpSpreadsheet Function
|
Excel Function | Category | PhpSpreadsheet Function
|
||||||
--------------------|--------------------------------|-------------------------------------------
|
--------------------|--------------------------------|-------------------------------------------
|
||||||
IF | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::STATEMENT_IF
|
IF | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::statementIf
|
||||||
IFERROR | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::IFERROR
|
IFERROR | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::IFERROR
|
||||||
IFNA | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::IFNA
|
IFNA | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::IFNA
|
||||||
IFS | CATEGORY_LOGICAL | **Not yet Implemented**
|
IFS | CATEGORY_LOGICAL | **Not yet Implemented**
|
||||||
|
@ -242,20 +244,20 @@ INTERCEPT | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet
|
||||||
INTRATE | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::INTRATE
|
INTRATE | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::INTRATE
|
||||||
IPMT | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::IPMT
|
IPMT | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::IPMT
|
||||||
IRR | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::IRR
|
IRR | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::IRR
|
||||||
ISBLANK | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_BLANK
|
ISBLANK | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isBlank
|
||||||
ISERR | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_ERR
|
ISERR | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isErr
|
||||||
ISERROR | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_ERROR
|
ISERROR | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isError
|
||||||
ISEVEN | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_EVEN
|
ISEVEN | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isEven
|
||||||
ISFORMULA | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::ISFORMULA
|
ISFORMULA | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isFormula
|
||||||
ISLOGICAL | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_LOGICAL
|
ISLOGICAL | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isLogical
|
||||||
ISNA | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_NA
|
ISNA | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isNa
|
||||||
ISNONTEXT | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_NONTEXT
|
ISNONTEXT | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isNonText
|
||||||
ISNUMBER | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_NUMBER
|
ISNUMBER | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isNumber
|
||||||
ISODD | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_ODD
|
ISODD | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isOdd
|
||||||
ISOWEEKNUM | CATEGORY_DATE_AND_TIME | \PhpOffice\PhpSpreadsheet\Calculation\DateTime::ISOWEEKNUM
|
ISOWEEKNUM | CATEGORY_DATE_AND_TIME | \PhpOffice\PhpSpreadsheet\Calculation\DateTime::ISOWEEKNUM
|
||||||
ISPMT | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::ISPMT
|
ISPMT | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::ISPMT
|
||||||
ISREF | CATEGORY_INFORMATION | **Not yet Implemented**
|
ISREF | CATEGORY_INFORMATION | **Not yet Implemented**
|
||||||
ISTEXT | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::IS_TEXT
|
ISTEXT | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::isText
|
||||||
|
|
||||||
## J
|
## J
|
||||||
|
|
||||||
|
@ -281,7 +283,7 @@ LEN | CATEGORY_TEXT_AND_DATA | \PhpOffice\PhpSpreadsheet
|
||||||
LENB | CATEGORY_TEXT_AND_DATA | \PhpOffice\PhpSpreadsheet\Calculation\TextData::STRINGLENGTH
|
LENB | CATEGORY_TEXT_AND_DATA | \PhpOffice\PhpSpreadsheet\Calculation\TextData::STRINGLENGTH
|
||||||
LINEST | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::LINEST
|
LINEST | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::LINEST
|
||||||
LN | CATEGORY_MATH_AND_TRIG | log
|
LN | CATEGORY_MATH_AND_TRIG | log
|
||||||
LOG | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::LOG_BASE
|
LOG | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::logBase
|
||||||
LOG10 | CATEGORY_MATH_AND_TRIG | log10
|
LOG10 | CATEGORY_MATH_AND_TRIG | log10
|
||||||
LOGEST | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::LOGEST
|
LOGEST | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::LOGEST
|
||||||
LOGINV | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::LOGINV
|
LOGINV | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::LOGINV
|
||||||
|
@ -321,7 +323,7 @@ MULTINOMIAL | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet
|
||||||
|
|
||||||
Excel Function | Category | PhpSpreadsheet Function
|
Excel Function | Category | PhpSpreadsheet Function
|
||||||
--------------------|--------------------------------|-------------------------------------------
|
--------------------|--------------------------------|-------------------------------------------
|
||||||
N | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::N
|
N | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::n
|
||||||
NA | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::NA
|
NA | CATEGORY_INFORMATION | \PhpOffice\PhpSpreadsheet\Calculation\Functions::NA
|
||||||
NEGBINOMDIST | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::NEGBINOMDIST
|
NEGBINOMDIST | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::NEGBINOMDIST
|
||||||
NETWORKDAYS | CATEGORY_DATE_AND_TIME | \PhpOffice\PhpSpreadsheet\Calculation\DateTime::NETWORKDAYS
|
NETWORKDAYS | CATEGORY_DATE_AND_TIME | \PhpOffice\PhpSpreadsheet\Calculation\DateTime::NETWORKDAYS
|
||||||
|
@ -428,8 +430,8 @@ SQRT | CATEGORY_MATH_AND_TRIG | sqrt
|
||||||
SQRTPI | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::SQRTPI
|
SQRTPI | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::SQRTPI
|
||||||
STANDARDIZE | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STANDARDIZE
|
STANDARDIZE | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STANDARDIZE
|
||||||
STDEV | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEV
|
STDEV | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEV
|
||||||
STDEV.S | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEV
|
|
||||||
STDEV.P | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVP
|
STDEV.P | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVP
|
||||||
|
STDEV.S | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEV
|
||||||
STDEVA | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVA
|
STDEVA | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVA
|
||||||
STDEVP | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVP
|
STDEVP | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVP
|
||||||
STDEVPA | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVPA
|
STDEVPA | CATEGORY_STATISTICAL | \PhpOffice\PhpSpreadsheet\Calculation\Statistical::STDEVPA
|
||||||
|
@ -444,7 +446,7 @@ SUMSQ | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet
|
||||||
SUMX2MY2 | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::SUMX2MY2
|
SUMX2MY2 | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::SUMX2MY2
|
||||||
SUMX2PY2 | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::SUMX2PY2
|
SUMX2PY2 | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::SUMX2PY2
|
||||||
SUMXMY2 | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::SUMXMY2
|
SUMXMY2 | CATEGORY_MATH_AND_TRIG | \PhpOffice\PhpSpreadsheet\Calculation\MathTrig::SUMXMY2
|
||||||
SWITCH | CATEGORY_LOGICAL | **Not yet Implemented**
|
SWITCH | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::statementSwitch
|
||||||
SYD | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::SYD
|
SYD | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::SYD
|
||||||
|
|
||||||
## T
|
## T
|
||||||
|
@ -514,7 +516,6 @@ XIRR | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet
|
||||||
XNPV | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::XNPV
|
XNPV | CATEGORY_FINANCIAL | \PhpOffice\PhpSpreadsheet\Calculation\Financial::XNPV
|
||||||
XOR | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalXor
|
XOR | CATEGORY_LOGICAL | \PhpOffice\PhpSpreadsheet\Calculation\Logical::logicalXor
|
||||||
|
|
||||||
|
|
||||||
## Y
|
## Y
|
||||||
|
|
||||||
Excel Function | Category | PhpSpreadsheet Function
|
Excel Function | Category | PhpSpreadsheet Function
|
||||||
|
|
|
@ -14,7 +14,7 @@ installed with composer, it can be run like so:
|
||||||
|
|
||||||
``` sh
|
``` sh
|
||||||
cd /project/to/migrate/src
|
cd /project/to/migrate/src
|
||||||
/project/to/migrate/vendor/phpoffice/phpspreadsheet/bin/migrate-from-phpexcel
|
php /project/to/migrate/vendor/phpoffice/phpspreadsheet/bin/migrate-from-phpexcel
|
||||||
```
|
```
|
||||||
|
|
||||||
**Important** The tool will irreversibly modify your sources, be sure to
|
**Important** The tool will irreversibly modify your sources, be sure to
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
The following pages offer you some widely-used PhpSpreadsheet recipes.
|
The following pages offer you some widely-used PhpSpreadsheet recipes.
|
||||||
Please note that these do NOT offer complete documentation on specific
|
Please note that these do NOT offer complete documentation on specific
|
||||||
PhpSpreadsheet API functions, but just a bump to get you started. If you
|
PhpSpreadsheet API functions, but just a bump to get you started. If you
|
||||||
need specific API functions, please refer to the [API documentation](https://phpoffice.github.io/PhpSpreadsheet/master).
|
need specific API functions, please refer to the [API documentation](https://phpoffice.github.io/PhpSpreadsheet).
|
||||||
|
|
||||||
For example, [setting a worksheet's page orientation and size
|
For example, [setting a worksheet's page orientation and size
|
||||||
](#setting-a-worksheets-page-orientation-and-size) covers setting a page
|
](#setting-a-worksheets-page-orientation-and-size) covers setting a page
|
||||||
orientation to A4. Other paper formats, like US Letter, are not covered
|
orientation to A4. Other paper formats, like US Letter, are not covered
|
||||||
in this document, but in the PhpSpreadsheet [API documentation](https://phpoffice.github.io/PhpSpreadsheet/master).
|
in this document, but in the PhpSpreadsheet [API documentation](https://phpoffice.github.io/PhpSpreadsheet).
|
||||||
|
|
||||||
## Setting a spreadsheet's metadata
|
## Setting a spreadsheet's metadata
|
||||||
|
|
||||||
|
@ -301,7 +301,7 @@ $spreadsheet->getActiveSheet()->getPageSetup()
|
||||||
```
|
```
|
||||||
|
|
||||||
Note that there are additional page settings available. Please refer to
|
Note that there are additional page settings available. Please refer to
|
||||||
the [API documentation](https://phpoffice.github.io/PhpSpreadsheet/master) for all possible options.
|
the [API documentation](https://phpoffice.github.io/PhpSpreadsheet) for all possible options.
|
||||||
|
|
||||||
### Page Setup: Scaling options
|
### Page Setup: Scaling options
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,9 @@
|
||||||
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/7.5/phpunit.xsd"
|
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/7.5/phpunit.xsd"
|
||||||
bootstrap="./tests/bootstrap.php"
|
bootstrap="./tests/bootstrap.php"
|
||||||
backupGlobals="true"
|
backupGlobals="true"
|
||||||
colors="true">
|
colors="true"
|
||||||
|
cacheResultFile="/tmp/.phpspreadsheet.phpunit.result.cache"
|
||||||
|
>
|
||||||
<php>
|
<php>
|
||||||
<ini name="memory_limit" value="2048M"/>
|
<ini name="memory_limit" value="2048M"/>
|
||||||
</php>
|
</php>
|
||||||
|
|
|
@ -4,7 +4,6 @@ use PhpOffice\PhpSpreadsheet\Spreadsheet;
|
||||||
|
|
||||||
require __DIR__ . '/../Header.php';
|
require __DIR__ . '/../Header.php';
|
||||||
|
|
||||||
$spreadsheet = new Spreadsheet();
|
|
||||||
$helper->log('Create new Spreadsheet object');
|
$helper->log('Create new Spreadsheet object');
|
||||||
$spreadsheet = new Spreadsheet();
|
$spreadsheet = new Spreadsheet();
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
require_once 'Header.php';
|
require_once 'Header.php';
|
||||||
|
|
||||||
$requirements = [
|
$requirements = [
|
||||||
'PHP 7.1.0' => version_compare(PHP_VERSION, '7.1.0', '>='),
|
'PHP 7.2.0' => version_compare(PHP_VERSION, '7.2.0', '>='),
|
||||||
'PHP extension XML' => extension_loaded('xml'),
|
'PHP extension XML' => extension_loaded('xml'),
|
||||||
'PHP extension xmlwriter' => extension_loaded('xmlwriter'),
|
'PHP extension xmlwriter' => extension_loaded('xmlwriter'),
|
||||||
'PHP extension mbstring' => extension_loaded('mbstring'),
|
'PHP extension mbstring' => extension_loaded('mbstring'),
|
||||||
|
|
|
@ -263,6 +263,11 @@ class Calculation
|
||||||
'functionCall' => [Logical::class, 'logicalAnd'],
|
'functionCall' => [Logical::class, 'logicalAnd'],
|
||||||
'argumentCount' => '1+',
|
'argumentCount' => '1+',
|
||||||
],
|
],
|
||||||
|
'ARABIC' => [
|
||||||
|
'category' => Category::CATEGORY_MATH_AND_TRIG,
|
||||||
|
'functionCall' => [MathTrig::class, 'ARABIC'],
|
||||||
|
'argumentCount' => '1',
|
||||||
|
],
|
||||||
'AREAS' => [
|
'AREAS' => [
|
||||||
'category' => Category::CATEGORY_LOOKUP_AND_REFERENCE,
|
'category' => Category::CATEGORY_LOOKUP_AND_REFERENCE,
|
||||||
'functionCall' => [Functions::class, 'DUMMY'],
|
'functionCall' => [Functions::class, 'DUMMY'],
|
||||||
|
@ -328,6 +333,11 @@ class Calculation
|
||||||
'functionCall' => [Functions::class, 'DUMMY'],
|
'functionCall' => [Functions::class, 'DUMMY'],
|
||||||
'argumentCount' => '1',
|
'argumentCount' => '1',
|
||||||
],
|
],
|
||||||
|
'BASE' => [
|
||||||
|
'category' => Category::CATEGORY_MATH_AND_TRIG,
|
||||||
|
'functionCall' => [MathTrig::class, 'BASE'],
|
||||||
|
'argumentCount' => '2,3',
|
||||||
|
],
|
||||||
'BESSELI' => [
|
'BESSELI' => [
|
||||||
'category' => Category::CATEGORY_ENGINEERING,
|
'category' => Category::CATEGORY_ENGINEERING,
|
||||||
'functionCall' => [Engineering::class, 'BESSELI'],
|
'functionCall' => [Engineering::class, 'BESSELI'],
|
||||||
|
@ -904,6 +914,16 @@ class Calculation
|
||||||
'functionCall' => [MathTrig::class, 'FLOOR'],
|
'functionCall' => [MathTrig::class, 'FLOOR'],
|
||||||
'argumentCount' => '2',
|
'argumentCount' => '2',
|
||||||
],
|
],
|
||||||
|
'FLOOR.MATH' => [
|
||||||
|
'category' => Category::CATEGORY_MATH_AND_TRIG,
|
||||||
|
'functionCall' => [MathTrig::class, 'FLOORMATH'],
|
||||||
|
'argumentCount' => '3',
|
||||||
|
],
|
||||||
|
'FLOOR.PRECISE' => [
|
||||||
|
'category' => Category::CATEGORY_MATH_AND_TRIG,
|
||||||
|
'functionCall' => [MathTrig::class, 'FLOORPRECISE'],
|
||||||
|
'argumentCount' => '2',
|
||||||
|
],
|
||||||
'FORECAST' => [
|
'FORECAST' => [
|
||||||
'category' => Category::CATEGORY_STATISTICAL,
|
'category' => Category::CATEGORY_STATISTICAL,
|
||||||
'functionCall' => [Statistical::class, 'FORECAST'],
|
'functionCall' => [Statistical::class, 'FORECAST'],
|
||||||
|
@ -1032,6 +1052,11 @@ class Calculation
|
||||||
'functionCall' => [Logical::class, 'IFNA'],
|
'functionCall' => [Logical::class, 'IFNA'],
|
||||||
'argumentCount' => '2',
|
'argumentCount' => '2',
|
||||||
],
|
],
|
||||||
|
'IFS' => [
|
||||||
|
'category' => Category::CATEGORY_LOGICAL,
|
||||||
|
'functionCall' => [Functions::class, 'DUMMY'],
|
||||||
|
'argumentCount' => '2+',
|
||||||
|
],
|
||||||
'IMABS' => [
|
'IMABS' => [
|
||||||
'category' => Category::CATEGORY_ENGINEERING,
|
'category' => Category::CATEGORY_ENGINEERING,
|
||||||
'functionCall' => [Engineering::class, 'IMABS'],
|
'functionCall' => [Engineering::class, 'IMABS'],
|
||||||
|
@ -1488,7 +1513,12 @@ class Calculation
|
||||||
'NETWORKDAYS' => [
|
'NETWORKDAYS' => [
|
||||||
'category' => Category::CATEGORY_DATE_AND_TIME,
|
'category' => Category::CATEGORY_DATE_AND_TIME,
|
||||||
'functionCall' => [DateTime::class, 'NETWORKDAYS'],
|
'functionCall' => [DateTime::class, 'NETWORKDAYS'],
|
||||||
'argumentCount' => '2+',
|
'argumentCount' => '2-3',
|
||||||
|
],
|
||||||
|
'NETWORKDAYS.INTL' => [
|
||||||
|
'category' => Category::CATEGORY_DATE_AND_TIME,
|
||||||
|
'functionCall' => [Functions::class, 'DUMMY'],
|
||||||
|
'argumentCount' => '2-4',
|
||||||
],
|
],
|
||||||
'NOMINAL' => [
|
'NOMINAL' => [
|
||||||
'category' => Category::CATEGORY_FINANCIAL,
|
'category' => Category::CATEGORY_FINANCIAL,
|
||||||
|
@ -2157,7 +2187,12 @@ class Calculation
|
||||||
'WORKDAY' => [
|
'WORKDAY' => [
|
||||||
'category' => Category::CATEGORY_DATE_AND_TIME,
|
'category' => Category::CATEGORY_DATE_AND_TIME,
|
||||||
'functionCall' => [DateTime::class, 'WORKDAY'],
|
'functionCall' => [DateTime::class, 'WORKDAY'],
|
||||||
'argumentCount' => '2+',
|
'argumentCount' => '2-3',
|
||||||
|
],
|
||||||
|
'WORKDAY.INTL' => [
|
||||||
|
'category' => Category::CATEGORY_DATE_AND_TIME,
|
||||||
|
'functionCall' => [Functions::class, 'DUMMY'],
|
||||||
|
'argumentCount' => '2-4',
|
||||||
],
|
],
|
||||||
'XIRR' => [
|
'XIRR' => [
|
||||||
'category' => Category::CATEGORY_FINANCIAL,
|
'category' => Category::CATEGORY_FINANCIAL,
|
||||||
|
@ -2210,7 +2245,7 @@ class Calculation
|
||||||
private static $controlFunctions = [
|
private static $controlFunctions = [
|
||||||
'MKMATRIX' => [
|
'MKMATRIX' => [
|
||||||
'argumentCount' => '*',
|
'argumentCount' => '*',
|
||||||
'functionCall' => 'self::mkMatrix',
|
'functionCall' => [__CLASS__, 'mkMatrix'],
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -3712,7 +3747,7 @@ class Calculation
|
||||||
} elseif (isset(self::$operators[$opCharacter]) && !$expectingOperator) {
|
} elseif (isset(self::$operators[$opCharacter]) && !$expectingOperator) {
|
||||||
return $this->raiseFormulaError("Formula Error: Unexpected operator '$opCharacter'");
|
return $this->raiseFormulaError("Formula Error: Unexpected operator '$opCharacter'");
|
||||||
} else { // I don't even want to know what you did to get here
|
} else { // I don't even want to know what you did to get here
|
||||||
return $this->raiseFormulaError('Formula Error: An unexpected error occured');
|
return $this->raiseFormulaError('Formula Error: An unexpected error occurred');
|
||||||
}
|
}
|
||||||
// Test for end of formula string
|
// Test for end of formula string
|
||||||
if ($index == strlen($formula)) {
|
if ($index == strlen($formula)) {
|
||||||
|
@ -4159,13 +4194,6 @@ class Calculation
|
||||||
if ($pCellParent) {
|
if ($pCellParent) {
|
||||||
$pCell->attach($pCellParent);
|
$pCell->attach($pCellParent);
|
||||||
}
|
}
|
||||||
if (($cellID == 'AC99') || (isset($pCell) && $pCell->getCoordinate() == 'AC99')) {
|
|
||||||
if (defined('RESOLVING')) {
|
|
||||||
define('RESOLVING2', true);
|
|
||||||
} else {
|
|
||||||
define('RESOLVING', true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$functionName = $matches[1];
|
$functionName = $matches[1];
|
||||||
$argCount = $stack->pop();
|
$argCount = $stack->pop();
|
||||||
|
|
|
@ -878,6 +878,8 @@ class DateTime
|
||||||
*
|
*
|
||||||
* Excel Function:
|
* Excel Function:
|
||||||
* YEARFRAC(startDate,endDate[,method])
|
* YEARFRAC(startDate,endDate[,method])
|
||||||
|
* See https://lists.oasis-open.org/archives/office-formula/200806/msg00039.html
|
||||||
|
* for description of algorithm used in Excel
|
||||||
*
|
*
|
||||||
* @category Date/Time Functions
|
* @category Date/Time Functions
|
||||||
*
|
*
|
||||||
|
@ -906,6 +908,11 @@ class DateTime
|
||||||
if (is_string($endDate = self::getDateValue($endDate))) {
|
if (is_string($endDate = self::getDateValue($endDate))) {
|
||||||
return Functions::VALUE();
|
return Functions::VALUE();
|
||||||
}
|
}
|
||||||
|
if ($startDate > $endDate) {
|
||||||
|
$temp = $startDate;
|
||||||
|
$startDate = $endDate;
|
||||||
|
$endDate = $temp;
|
||||||
|
}
|
||||||
|
|
||||||
if (((is_numeric($method)) && (!is_string($method))) || ($method == '')) {
|
if (((is_numeric($method)) && (!is_string($method))) || ($method == '')) {
|
||||||
switch ($method) {
|
switch ($method) {
|
||||||
|
@ -916,46 +923,43 @@ class DateTime
|
||||||
$startYear = self::YEAR($startDate);
|
$startYear = self::YEAR($startDate);
|
||||||
$endYear = self::YEAR($endDate);
|
$endYear = self::YEAR($endDate);
|
||||||
$years = $endYear - $startYear + 1;
|
$years = $endYear - $startYear + 1;
|
||||||
$leapDays = 0;
|
|
||||||
if ($years == 1) {
|
|
||||||
if (self::isLeapYear($endYear)) {
|
|
||||||
$startMonth = self::MONTHOFYEAR($startDate);
|
|
||||||
$endMonth = self::MONTHOFYEAR($endDate);
|
|
||||||
$endDay = self::DAYOFMONTH($endDate);
|
|
||||||
if (($startMonth < 3) ||
|
|
||||||
(($endMonth * 100 + $endDay) >= (2 * 100 + 29))) {
|
|
||||||
$leapDays += 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
for ($year = $startYear; $year <= $endYear; ++$year) {
|
|
||||||
if ($year == $startYear) {
|
|
||||||
$startMonth = self::MONTHOFYEAR($startDate);
|
$startMonth = self::MONTHOFYEAR($startDate);
|
||||||
$startDay = self::DAYOFMONTH($startDate);
|
$startDay = self::DAYOFMONTH($startDate);
|
||||||
if ($startMonth < 3) {
|
|
||||||
$leapDays += (self::isLeapYear($year)) ? 1 : 0;
|
|
||||||
}
|
|
||||||
} elseif ($year == $endYear) {
|
|
||||||
$endMonth = self::MONTHOFYEAR($endDate);
|
$endMonth = self::MONTHOFYEAR($endDate);
|
||||||
$endDay = self::DAYOFMONTH($endDate);
|
$endDay = self::DAYOFMONTH($endDate);
|
||||||
if (($endMonth * 100 + $endDay) >= (2 * 100 + 29)) {
|
$startMonthDay = 100 * $startMonth + $startDay;
|
||||||
$leapDays += (self::isLeapYear($year)) ? 1 : 0;
|
$endMonthDay = 100 * $endMonth + $endDay;
|
||||||
|
if ($years == 1) {
|
||||||
|
if (self::isLeapYear($endYear)) {
|
||||||
|
$tmpCalcAnnualBasis = 366;
|
||||||
|
} else {
|
||||||
|
$tmpCalcAnnualBasis = 365;
|
||||||
|
}
|
||||||
|
} elseif ($years == 2 && $startMonthDay >= $endMonthDay) {
|
||||||
|
if (self::isLeapYear($startYear)) {
|
||||||
|
if ($startMonthDay <= 229) {
|
||||||
|
$tmpCalcAnnualBasis = 366;
|
||||||
|
} else {
|
||||||
|
$tmpCalcAnnualBasis = 365;
|
||||||
|
}
|
||||||
|
} elseif (self::isLeapYear($endYear)) {
|
||||||
|
if ($endMonthDay >= 229) {
|
||||||
|
$tmpCalcAnnualBasis = 366;
|
||||||
|
} else {
|
||||||
|
$tmpCalcAnnualBasis = 365;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$leapDays += (self::isLeapYear($year)) ? 1 : 0;
|
$tmpCalcAnnualBasis = 365;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
$tmpCalcAnnualBasis = 0;
|
||||||
|
for ($year = $startYear; $year <= $endYear; ++$year) {
|
||||||
|
$tmpCalcAnnualBasis += self::isLeapYear($year) ? 366 : 365;
|
||||||
}
|
}
|
||||||
if ($years == 2) {
|
$tmpCalcAnnualBasis /= $years;
|
||||||
if (($leapDays == 0) && (self::isLeapYear($startYear)) && ($days > 365)) {
|
|
||||||
$leapDays = 1;
|
|
||||||
} elseif ($days < 366) {
|
|
||||||
$years = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
$leapDays /= $years;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return $days / (365 + $leapDays);
|
return $days / $tmpCalcAnnualBasis;
|
||||||
case 2:
|
case 2:
|
||||||
return self::DATEDIF($startDate, $endDate) / 360;
|
return self::DATEDIF($startDate, $endDate) / 360;
|
||||||
case 3:
|
case 3:
|
||||||
|
@ -1273,6 +1277,36 @@ class DateTime
|
||||||
return $DoW;
|
return $DoW;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const STARTWEEK_SUNDAY = 1;
|
||||||
|
const STARTWEEK_MONDAY = 2;
|
||||||
|
const STARTWEEK_MONDAY_ALT = 11;
|
||||||
|
const STARTWEEK_TUESDAY = 12;
|
||||||
|
const STARTWEEK_WEDNESDAY = 13;
|
||||||
|
const STARTWEEK_THURSDAY = 14;
|
||||||
|
const STARTWEEK_FRIDAY = 15;
|
||||||
|
const STARTWEEK_SATURDAY = 16;
|
||||||
|
const STARTWEEK_SUNDAY_ALT = 17;
|
||||||
|
const DOW_SUNDAY = 1;
|
||||||
|
const DOW_MONDAY = 2;
|
||||||
|
const DOW_TUESDAY = 3;
|
||||||
|
const DOW_WEDNESDAY = 4;
|
||||||
|
const DOW_THURSDAY = 5;
|
||||||
|
const DOW_FRIDAY = 6;
|
||||||
|
const DOW_SATURDAY = 7;
|
||||||
|
const STARTWEEK_MONDAY_ISO = 21;
|
||||||
|
const METHODARR = [
|
||||||
|
self::STARTWEEK_SUNDAY => self::DOW_SUNDAY,
|
||||||
|
self::DOW_MONDAY,
|
||||||
|
self::STARTWEEK_MONDAY_ALT => self::DOW_MONDAY,
|
||||||
|
self::DOW_TUESDAY,
|
||||||
|
self::DOW_WEDNESDAY,
|
||||||
|
self::DOW_THURSDAY,
|
||||||
|
self::DOW_FRIDAY,
|
||||||
|
self::DOW_SATURDAY,
|
||||||
|
self::DOW_SUNDAY,
|
||||||
|
self::STARTWEEK_MONDAY_ISO => self::STARTWEEK_MONDAY_ISO,
|
||||||
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* WEEKNUM.
|
* WEEKNUM.
|
||||||
*
|
*
|
||||||
|
@ -1291,41 +1325,51 @@ class DateTime
|
||||||
* @param int $method Week begins on Sunday or Monday
|
* @param int $method Week begins on Sunday or Monday
|
||||||
* 1 or omitted Week begins on Sunday.
|
* 1 or omitted Week begins on Sunday.
|
||||||
* 2 Week begins on Monday.
|
* 2 Week begins on Monday.
|
||||||
|
* 11 Week begins on Monday.
|
||||||
|
* 12 Week begins on Tuesday.
|
||||||
|
* 13 Week begins on Wednesday.
|
||||||
|
* 14 Week begins on Thursday.
|
||||||
|
* 15 Week begins on Friday.
|
||||||
|
* 16 Week begins on Saturday.
|
||||||
|
* 17 Week begins on Sunday.
|
||||||
|
* 21 ISO (Jan. 4 is week 1, begins on Monday).
|
||||||
*
|
*
|
||||||
* @return int|string Week Number
|
* @return int|string Week Number
|
||||||
*/
|
*/
|
||||||
public static function WEEKNUM($dateValue = 1, $method = 1)
|
public static function WEEKNUM($dateValue = 1, $method = self::STARTWEEK_SUNDAY)
|
||||||
{
|
{
|
||||||
$dateValue = Functions::flattenSingleValue($dateValue);
|
$dateValue = Functions::flattenSingleValue($dateValue);
|
||||||
$method = Functions::flattenSingleValue($method);
|
$method = Functions::flattenSingleValue($method);
|
||||||
|
|
||||||
if (!is_numeric($method)) {
|
if (!is_numeric($method)) {
|
||||||
return Functions::VALUE();
|
return Functions::VALUE();
|
||||||
} elseif (($method < 1) || ($method > 2)) {
|
|
||||||
return Functions::NAN();
|
|
||||||
}
|
}
|
||||||
$method = floor($method);
|
$method = (int) $method;
|
||||||
|
if (!array_key_exists($method, self::METHODARR)) {
|
||||||
|
return Functions::NaN();
|
||||||
|
}
|
||||||
|
$method = self::METHODARR[$method];
|
||||||
|
|
||||||
if ($dateValue === null) {
|
$dateValue = self::getDateValue($dateValue);
|
||||||
$dateValue = 1;
|
if (is_string($dateValue)) {
|
||||||
} elseif (is_string($dateValue = self::getDateValue($dateValue))) {
|
|
||||||
return Functions::VALUE();
|
return Functions::VALUE();
|
||||||
} elseif ($dateValue < 0.0) {
|
}
|
||||||
|
if ($dateValue < 0.0) {
|
||||||
return Functions::NAN();
|
return Functions::NAN();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Execute function
|
// Execute function
|
||||||
$PHPDateObject = Date::excelToDateTimeObject($dateValue);
|
$PHPDateObject = Date::excelToDateTimeObject($dateValue);
|
||||||
|
if ($method == self::STARTWEEK_MONDAY_ISO) {
|
||||||
|
return (int) $PHPDateObject->format('W');
|
||||||
|
}
|
||||||
$dayOfYear = $PHPDateObject->format('z');
|
$dayOfYear = $PHPDateObject->format('z');
|
||||||
$PHPDateObject->modify('-' . $dayOfYear . ' days');
|
$PHPDateObject->modify('-' . $dayOfYear . ' days');
|
||||||
$firstDayOfFirstWeek = $PHPDateObject->format('w');
|
$firstDayOfFirstWeek = $PHPDateObject->format('w');
|
||||||
$daysInFirstWeek = (6 - $firstDayOfFirstWeek + $method) % 7;
|
$daysInFirstWeek = (6 - $firstDayOfFirstWeek + $method) % 7;
|
||||||
$interval = $dayOfYear - $daysInFirstWeek;
|
$daysInFirstWeek += 7 * !$daysInFirstWeek;
|
||||||
$weekOfYear = floor($interval / 7) + 1;
|
$endFirstWeek = $daysInFirstWeek - 1;
|
||||||
|
$weekOfYear = floor(($dayOfYear - $endFirstWeek + 13) / 7);
|
||||||
if ($daysInFirstWeek) {
|
|
||||||
++$weekOfYear;
|
|
||||||
}
|
|
||||||
|
|
||||||
return (int) $weekOfYear;
|
return (int) $weekOfYear;
|
||||||
}
|
}
|
||||||
|
|
|
@ -646,7 +646,7 @@ class Functions
|
||||||
public static function flattenSingleValue($value = '')
|
public static function flattenSingleValue($value = '')
|
||||||
{
|
{
|
||||||
while (is_array($value)) {
|
while (is_array($value)) {
|
||||||
$value = array_pop($value);
|
$value = array_shift($value);
|
||||||
}
|
}
|
||||||
|
|
||||||
return $value;
|
return $value;
|
||||||
|
|
|
@ -38,6 +38,88 @@ class MathTrig
|
||||||
return ($num - ($num % $n)) / $n;
|
return ($num - ($num % $n)) / $n;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ARABIC.
|
||||||
|
*
|
||||||
|
* Converts a Roman numeral to an Arabic numeral.
|
||||||
|
*
|
||||||
|
* Excel Function:
|
||||||
|
* ARABIC(text)
|
||||||
|
*
|
||||||
|
* @category Mathematical and Trigonometric Functions
|
||||||
|
*
|
||||||
|
* @param string $roman
|
||||||
|
*
|
||||||
|
* @return int|string the arabic numberal contrived from the roman numeral
|
||||||
|
*/
|
||||||
|
public static function ARABIC($roman)
|
||||||
|
{
|
||||||
|
// An empty string should return 0
|
||||||
|
$roman = substr(trim(strtoupper((string) Functions::flattenSingleValue($roman))), 0, 255);
|
||||||
|
if ($roman === '') {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Convert the roman numeral to an arabic number
|
||||||
|
$negativeNumber = $roman[0] === '-';
|
||||||
|
if ($negativeNumber) {
|
||||||
|
$roman = substr($roman, 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
$arabic = self::calculateArabic(str_split($roman));
|
||||||
|
} catch (\Exception $e) {
|
||||||
|
return Functions::VALUE(); // Invalid character detected
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($negativeNumber) {
|
||||||
|
$arabic *= -1; // The number should be negative
|
||||||
|
}
|
||||||
|
|
||||||
|
return $arabic;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Recursively calculate the arabic value of a roman numeral.
|
||||||
|
*
|
||||||
|
* @param array $roman
|
||||||
|
* @param int $sum
|
||||||
|
* @param int $subtract
|
||||||
|
*
|
||||||
|
* @return int
|
||||||
|
*/
|
||||||
|
protected static function calculateArabic(array $roman, &$sum = 0, $subtract = 0)
|
||||||
|
{
|
||||||
|
$lookup = [
|
||||||
|
'M' => 1000,
|
||||||
|
'D' => 500,
|
||||||
|
'C' => 100,
|
||||||
|
'L' => 50,
|
||||||
|
'X' => 10,
|
||||||
|
'V' => 5,
|
||||||
|
'I' => 1,
|
||||||
|
];
|
||||||
|
|
||||||
|
$numeral = array_shift($roman);
|
||||||
|
if (!isset($lookup[$numeral])) {
|
||||||
|
throw new \Exception('Invalid character detected');
|
||||||
|
}
|
||||||
|
|
||||||
|
$arabic = $lookup[$numeral];
|
||||||
|
if (count($roman) > 0 && isset($lookup[$roman[0]]) && $arabic < $lookup[$roman[0]]) {
|
||||||
|
$subtract += $arabic;
|
||||||
|
} else {
|
||||||
|
$sum += ($arabic - $subtract);
|
||||||
|
$subtract = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (count($roman) > 0) {
|
||||||
|
self::calculateArabic($roman, $sum, $subtract);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $sum;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ATAN2.
|
* ATAN2.
|
||||||
*
|
*
|
||||||
|
@ -84,6 +166,49 @@ class MathTrig
|
||||||
return Functions::VALUE();
|
return Functions::VALUE();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* BASE.
|
||||||
|
*
|
||||||
|
* Converts a number into a text representation with the given radix (base).
|
||||||
|
*
|
||||||
|
* Excel Function:
|
||||||
|
* BASE(Number, Radix [Min_length])
|
||||||
|
*
|
||||||
|
* @category Mathematical and Trigonometric Functions
|
||||||
|
*
|
||||||
|
* @param float $number
|
||||||
|
* @param float $radix
|
||||||
|
* @param int $minLength
|
||||||
|
*
|
||||||
|
* @return string the text representation with the given radix (base)
|
||||||
|
*/
|
||||||
|
public static function BASE($number, $radix, $minLength = null)
|
||||||
|
{
|
||||||
|
$number = Functions::flattenSingleValue($number);
|
||||||
|
$radix = Functions::flattenSingleValue($radix);
|
||||||
|
$minLength = Functions::flattenSingleValue($minLength);
|
||||||
|
|
||||||
|
if (is_numeric($number) && is_numeric($radix) && ($minLength === null || is_numeric($minLength))) {
|
||||||
|
// Truncate to an integer
|
||||||
|
$number = (int) $number;
|
||||||
|
$radix = (int) $radix;
|
||||||
|
$minLength = (int) $minLength;
|
||||||
|
|
||||||
|
if ($number < 0 || $number >= 2 ** 53 || $radix < 2 || $radix > 36) {
|
||||||
|
return Functions::NAN(); // Numeric range constraints
|
||||||
|
}
|
||||||
|
|
||||||
|
$outcome = strtoupper((string) base_convert($number, 10, $radix));
|
||||||
|
if ($minLength !== null) {
|
||||||
|
$outcome = str_pad($outcome, $minLength, '0', STR_PAD_LEFT); // String padding
|
||||||
|
}
|
||||||
|
|
||||||
|
return $outcome;
|
||||||
|
}
|
||||||
|
|
||||||
|
return Functions::VALUE();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* CEILING.
|
* CEILING.
|
||||||
*
|
*
|
||||||
|
@ -313,6 +438,80 @@ class MathTrig
|
||||||
return Functions::VALUE();
|
return Functions::VALUE();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* FLOOR.MATH.
|
||||||
|
*
|
||||||
|
* Round a number down to the nearest integer or to the nearest multiple of significance.
|
||||||
|
*
|
||||||
|
* Excel Function:
|
||||||
|
* FLOOR.MATH(number[,significance[,mode]])
|
||||||
|
*
|
||||||
|
* @category Mathematical and Trigonometric Functions
|
||||||
|
*
|
||||||
|
* @param float $number Number to round
|
||||||
|
* @param float $significance Significance
|
||||||
|
* @param int $mode direction to round negative numbers
|
||||||
|
*
|
||||||
|
* @return float|string Rounded Number, or a string containing an error
|
||||||
|
*/
|
||||||
|
public static function FLOORMATH($number, $significance = null, $mode = 0)
|
||||||
|
{
|
||||||
|
$number = Functions::flattenSingleValue($number);
|
||||||
|
$significance = Functions::flattenSingleValue($significance);
|
||||||
|
$mode = Functions::flattenSingleValue($mode);
|
||||||
|
|
||||||
|
if (is_numeric($number) && $significance === null) {
|
||||||
|
$significance = $number / abs($number);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (is_numeric($number) && is_numeric($significance) && is_numeric($mode)) {
|
||||||
|
if ($significance == 0.0) {
|
||||||
|
return Functions::DIV0();
|
||||||
|
} elseif ($number == 0.0) {
|
||||||
|
return 0.0;
|
||||||
|
} elseif (self::SIGN($significance) == -1 || (self::SIGN($number) == -1 && !empty($mode))) {
|
||||||
|
return ceil($number / $significance) * $significance;
|
||||||
|
}
|
||||||
|
|
||||||
|
return floor($number / $significance) * $significance;
|
||||||
|
}
|
||||||
|
|
||||||
|
return Functions::VALUE();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* FLOOR.PRECISE.
|
||||||
|
*
|
||||||
|
* Rounds number down, toward zero, to the nearest multiple of significance.
|
||||||
|
*
|
||||||
|
* Excel Function:
|
||||||
|
* FLOOR.PRECISE(number[,significance])
|
||||||
|
*
|
||||||
|
* @category Mathematical and Trigonometric Functions
|
||||||
|
*
|
||||||
|
* @param float $number Number to round
|
||||||
|
* @param float $significance Significance
|
||||||
|
*
|
||||||
|
* @return float|string Rounded Number, or a string containing an error
|
||||||
|
*/
|
||||||
|
public static function FLOORPRECISE($number, $significance = 1)
|
||||||
|
{
|
||||||
|
$number = Functions::flattenSingleValue($number);
|
||||||
|
$significance = Functions::flattenSingleValue($significance);
|
||||||
|
|
||||||
|
if ((is_numeric($number)) && (is_numeric($significance))) {
|
||||||
|
if ($significance == 0.0) {
|
||||||
|
return Functions::DIV0();
|
||||||
|
} elseif ($number == 0.0) {
|
||||||
|
return 0.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
return floor($number / abs($significance)) * abs($significance);
|
||||||
|
}
|
||||||
|
|
||||||
|
return Functions::VALUE();
|
||||||
|
}
|
||||||
|
|
||||||
private static function evaluateGCD($a, $b)
|
private static function evaluateGCD($a, $b)
|
||||||
{
|
{
|
||||||
return $b ? self::evaluateGCD($b, $a % $b) : $a;
|
return $b ? self::evaluateGCD($b, $a % $b) : $a;
|
||||||
|
@ -939,12 +1138,11 @@ class MathTrig
|
||||||
$digits = Functions::flattenSingleValue($digits);
|
$digits = Functions::flattenSingleValue($digits);
|
||||||
|
|
||||||
if ((is_numeric($number)) && (is_numeric($digits))) {
|
if ((is_numeric($number)) && (is_numeric($digits))) {
|
||||||
$significance = pow(10, (int) $digits);
|
|
||||||
if ($number < 0.0) {
|
if ($number < 0.0) {
|
||||||
return floor($number * $significance) / $significance;
|
return round($number - 0.5 * pow(0.1, $digits), $digits, PHP_ROUND_HALF_DOWN);
|
||||||
}
|
}
|
||||||
|
|
||||||
return ceil($number * $significance) / $significance;
|
return round($number + 0.5 * pow(0.1, $digits), $digits, PHP_ROUND_HALF_DOWN);
|
||||||
}
|
}
|
||||||
|
|
||||||
return Functions::VALUE();
|
return Functions::VALUE();
|
||||||
|
@ -966,12 +1164,11 @@ class MathTrig
|
||||||
$digits = Functions::flattenSingleValue($digits);
|
$digits = Functions::flattenSingleValue($digits);
|
||||||
|
|
||||||
if ((is_numeric($number)) && (is_numeric($digits))) {
|
if ((is_numeric($number)) && (is_numeric($digits))) {
|
||||||
$significance = pow(10, (int) $digits);
|
|
||||||
if ($number < 0.0) {
|
if ($number < 0.0) {
|
||||||
return ceil($number * $significance) / $significance;
|
return round($number + 0.5 * pow(0.1, $digits), $digits, PHP_ROUND_HALF_UP);
|
||||||
}
|
}
|
||||||
|
|
||||||
return floor($number * $significance) / $significance;
|
return round($number - 0.5 * pow(0.1, $digits), $digits, PHP_ROUND_HALF_UP);
|
||||||
}
|
}
|
||||||
|
|
||||||
return Functions::VALUE();
|
return Functions::VALUE();
|
||||||
|
|
|
@ -9,6 +9,7 @@ ADDRESS
|
||||||
AMORDEGRC
|
AMORDEGRC
|
||||||
AMORLINC
|
AMORLINC
|
||||||
AND
|
AND
|
||||||
|
ARABIC
|
||||||
AREAS
|
AREAS
|
||||||
ASC
|
ASC
|
||||||
ASIN
|
ASIN
|
||||||
|
@ -22,6 +23,7 @@ AVERAGEA
|
||||||
AVERAGEIF
|
AVERAGEIF
|
||||||
AVERAGEIFS
|
AVERAGEIFS
|
||||||
BAHTTEXT
|
BAHTTEXT
|
||||||
|
BASE
|
||||||
BESSELI
|
BESSELI
|
||||||
BESSELJ
|
BESSELJ
|
||||||
BESSELK
|
BESSELK
|
||||||
|
@ -137,6 +139,8 @@ FISHER
|
||||||
FISHERINV
|
FISHERINV
|
||||||
FIXED
|
FIXED
|
||||||
FLOOR
|
FLOOR
|
||||||
|
FLOOR.MATH
|
||||||
|
FLOOR.PRECISE
|
||||||
FORECAST
|
FORECAST
|
||||||
FREQUENCY
|
FREQUENCY
|
||||||
FTEST
|
FTEST
|
||||||
|
|
|
@ -67,7 +67,7 @@ class Cell
|
||||||
/**
|
/**
|
||||||
* Update the cell into the cell collection.
|
* Update the cell into the cell collection.
|
||||||
*
|
*
|
||||||
* @return self
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function updateInCollection()
|
public function updateInCollection()
|
||||||
{
|
{
|
||||||
|
@ -177,7 +177,7 @@ class Cell
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Cell
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setValue($pValue)
|
public function setValue($pValue)
|
||||||
{
|
{
|
||||||
|
@ -266,7 +266,7 @@ class Cell
|
||||||
// We don't yet handle array returns
|
// We don't yet handle array returns
|
||||||
if (is_array($result)) {
|
if (is_array($result)) {
|
||||||
while (is_array($result)) {
|
while (is_array($result)) {
|
||||||
$result = array_pop($result);
|
$result = array_shift($result);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (Exception $ex) {
|
} catch (Exception $ex) {
|
||||||
|
@ -672,7 +672,7 @@ class Cell
|
||||||
*
|
*
|
||||||
* @param mixed $pAttributes
|
* @param mixed $pAttributes
|
||||||
*
|
*
|
||||||
* @return Cell
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFormulaAttributes($pAttributes)
|
public function setFormulaAttributes($pAttributes)
|
||||||
{
|
{
|
||||||
|
|
|
@ -142,7 +142,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFormula1($value)
|
public function setFormula1($value)
|
||||||
{
|
{
|
||||||
|
@ -166,7 +166,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFormula2($value)
|
public function setFormula2($value)
|
||||||
{
|
{
|
||||||
|
@ -190,7 +190,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setType($value)
|
public function setType($value)
|
||||||
{
|
{
|
||||||
|
@ -214,7 +214,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param string $value see self::STYLE_*
|
* @param string $value see self::STYLE_*
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setErrorStyle($value)
|
public function setErrorStyle($value)
|
||||||
{
|
{
|
||||||
|
@ -238,7 +238,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOperator($value)
|
public function setOperator($value)
|
||||||
{
|
{
|
||||||
|
@ -262,7 +262,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param bool $value
|
* @param bool $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAllowBlank($value)
|
public function setAllowBlank($value)
|
||||||
{
|
{
|
||||||
|
@ -286,7 +286,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param bool $value
|
* @param bool $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowDropDown($value)
|
public function setShowDropDown($value)
|
||||||
{
|
{
|
||||||
|
@ -310,7 +310,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param bool $value
|
* @param bool $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowInputMessage($value)
|
public function setShowInputMessage($value)
|
||||||
{
|
{
|
||||||
|
@ -334,7 +334,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param bool $value
|
* @param bool $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowErrorMessage($value)
|
public function setShowErrorMessage($value)
|
||||||
{
|
{
|
||||||
|
@ -358,7 +358,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setErrorTitle($value)
|
public function setErrorTitle($value)
|
||||||
{
|
{
|
||||||
|
@ -382,7 +382,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setError($value)
|
public function setError($value)
|
||||||
{
|
{
|
||||||
|
@ -406,7 +406,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPromptTitle($value)
|
public function setPromptTitle($value)
|
||||||
{
|
{
|
||||||
|
@ -430,7 +430,7 @@ class DataValidation
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return DataValidation
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPrompt($value)
|
public function setPrompt($value)
|
||||||
{
|
{
|
||||||
|
|
|
@ -46,7 +46,7 @@ class Hyperlink
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return Hyperlink
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setUrl($value)
|
public function setUrl($value)
|
||||||
{
|
{
|
||||||
|
@ -70,7 +70,7 @@ class Hyperlink
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return Hyperlink
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setTooltip($value)
|
public function setTooltip($value)
|
||||||
{
|
{
|
||||||
|
|
|
@ -354,7 +354,7 @@ class Axis extends Properties
|
||||||
*
|
*
|
||||||
* @param int $shadow_presets
|
* @param int $shadow_presets
|
||||||
*
|
*
|
||||||
* @return Axis
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowPresetsProperties($shadow_presets)
|
private function setShadowPresetsProperties($shadow_presets)
|
||||||
{
|
{
|
||||||
|
@ -370,7 +370,7 @@ class Axis extends Properties
|
||||||
* @param array $properties_map
|
* @param array $properties_map
|
||||||
* @param mixed &$reference
|
* @param mixed &$reference
|
||||||
*
|
*
|
||||||
* @return Axis
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowProperiesMapValues(array $properties_map, &$reference = null)
|
private function setShadowProperiesMapValues(array $properties_map, &$reference = null)
|
||||||
{
|
{
|
||||||
|
@ -402,7 +402,7 @@ class Axis extends Properties
|
||||||
* @param int $alpha
|
* @param int $alpha
|
||||||
* @param string $type
|
* @param string $type
|
||||||
*
|
*
|
||||||
* @return Axis
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowColor($color, $alpha, $type)
|
private function setShadowColor($color, $alpha, $type)
|
||||||
{
|
{
|
||||||
|
@ -416,7 +416,7 @@ class Axis extends Properties
|
||||||
*
|
*
|
||||||
* @param float $blur
|
* @param float $blur
|
||||||
*
|
*
|
||||||
* @return Axis
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowBlur($blur)
|
private function setShadowBlur($blur)
|
||||||
{
|
{
|
||||||
|
@ -432,7 +432,7 @@ class Axis extends Properties
|
||||||
*
|
*
|
||||||
* @param int $angle
|
* @param int $angle
|
||||||
*
|
*
|
||||||
* @return Axis
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowAngle($angle)
|
private function setShadowAngle($angle)
|
||||||
{
|
{
|
||||||
|
@ -448,7 +448,7 @@ class Axis extends Properties
|
||||||
*
|
*
|
||||||
* @param float $distance
|
* @param float $distance
|
||||||
*
|
*
|
||||||
* @return Axis
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowDistance($distance)
|
private function setShadowDistance($distance)
|
||||||
{
|
{
|
||||||
|
@ -506,7 +506,7 @@ class Axis extends Properties
|
||||||
*
|
*
|
||||||
* @param float $size
|
* @param float $size
|
||||||
*
|
*
|
||||||
* @return Axis
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setGlowSize($size)
|
private function setGlowSize($size)
|
||||||
{
|
{
|
||||||
|
@ -524,7 +524,7 @@ class Axis extends Properties
|
||||||
* @param int $alpha
|
* @param int $alpha
|
||||||
* @param string $type
|
* @param string $type
|
||||||
*
|
*
|
||||||
* @return Axis
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setGlowColor($color, $alpha, $type)
|
private function setGlowColor($color, $alpha, $type)
|
||||||
{
|
{
|
||||||
|
|
|
@ -197,7 +197,7 @@ class Chart
|
||||||
*
|
*
|
||||||
* @param Worksheet $pValue
|
* @param Worksheet $pValue
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWorksheet(Worksheet $pValue = null)
|
public function setWorksheet(Worksheet $pValue = null)
|
||||||
{
|
{
|
||||||
|
@ -221,7 +221,7 @@ class Chart
|
||||||
*
|
*
|
||||||
* @param Title $title
|
* @param Title $title
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setTitle(Title $title)
|
public function setTitle(Title $title)
|
||||||
{
|
{
|
||||||
|
@ -245,7 +245,7 @@ class Chart
|
||||||
*
|
*
|
||||||
* @param Legend $legend
|
* @param Legend $legend
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLegend(Legend $legend)
|
public function setLegend(Legend $legend)
|
||||||
{
|
{
|
||||||
|
@ -269,7 +269,7 @@ class Chart
|
||||||
*
|
*
|
||||||
* @param Title $label
|
* @param Title $label
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setXAxisLabel(Title $label)
|
public function setXAxisLabel(Title $label)
|
||||||
{
|
{
|
||||||
|
@ -293,7 +293,7 @@ class Chart
|
||||||
*
|
*
|
||||||
* @param Title $label
|
* @param Title $label
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setYAxisLabel(Title $label)
|
public function setYAxisLabel(Title $label)
|
||||||
{
|
{
|
||||||
|
@ -327,7 +327,7 @@ class Chart
|
||||||
*
|
*
|
||||||
* @param bool $plotVisibleOnly
|
* @param bool $plotVisibleOnly
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPlotVisibleOnly($plotVisibleOnly)
|
public function setPlotVisibleOnly($plotVisibleOnly)
|
||||||
{
|
{
|
||||||
|
@ -351,7 +351,7 @@ class Chart
|
||||||
*
|
*
|
||||||
* @param string $displayBlanksAs
|
* @param string $displayBlanksAs
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDisplayBlanksAs($displayBlanksAs)
|
public function setDisplayBlanksAs($displayBlanksAs)
|
||||||
{
|
{
|
||||||
|
@ -423,7 +423,7 @@ class Chart
|
||||||
* @param int $xOffset
|
* @param int $xOffset
|
||||||
* @param int $yOffset
|
* @param int $yOffset
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setTopLeftPosition($cell, $xOffset = null, $yOffset = null)
|
public function setTopLeftPosition($cell, $xOffset = null, $yOffset = null)
|
||||||
{
|
{
|
||||||
|
@ -467,7 +467,7 @@ class Chart
|
||||||
*
|
*
|
||||||
* @param string $cell
|
* @param string $cell
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setTopLeftCell($cell)
|
public function setTopLeftCell($cell)
|
||||||
{
|
{
|
||||||
|
@ -482,7 +482,7 @@ class Chart
|
||||||
* @param int $xOffset
|
* @param int $xOffset
|
||||||
* @param int $yOffset
|
* @param int $yOffset
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setTopLeftOffset($xOffset, $yOffset)
|
public function setTopLeftOffset($xOffset, $yOffset)
|
||||||
{
|
{
|
||||||
|
@ -541,7 +541,7 @@ class Chart
|
||||||
* @param int $xOffset
|
* @param int $xOffset
|
||||||
* @param int $yOffset
|
* @param int $yOffset
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setBottomRightPosition($cell, $xOffset = null, $yOffset = null)
|
public function setBottomRightPosition($cell, $xOffset = null, $yOffset = null)
|
||||||
{
|
{
|
||||||
|
@ -593,7 +593,7 @@ class Chart
|
||||||
* @param int $xOffset
|
* @param int $xOffset
|
||||||
* @param int $yOffset
|
* @param int $yOffset
|
||||||
*
|
*
|
||||||
* @return Chart
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setBottomRightOffset($xOffset, $yOffset)
|
public function setBottomRightOffset($xOffset, $yOffset)
|
||||||
{
|
{
|
||||||
|
|
|
@ -157,7 +157,7 @@ class DataSeries
|
||||||
*
|
*
|
||||||
* @param string $plotType
|
* @param string $plotType
|
||||||
*
|
*
|
||||||
* @return DataSeries
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPlotType($plotType)
|
public function setPlotType($plotType)
|
||||||
{
|
{
|
||||||
|
@ -181,7 +181,7 @@ class DataSeries
|
||||||
*
|
*
|
||||||
* @param string $groupingType
|
* @param string $groupingType
|
||||||
*
|
*
|
||||||
* @return DataSeries
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPlotGrouping($groupingType)
|
public function setPlotGrouping($groupingType)
|
||||||
{
|
{
|
||||||
|
@ -205,7 +205,7 @@ class DataSeries
|
||||||
*
|
*
|
||||||
* @param string $plotDirection
|
* @param string $plotDirection
|
||||||
*
|
*
|
||||||
* @return DataSeries
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPlotDirection($plotDirection)
|
public function setPlotDirection($plotDirection)
|
||||||
{
|
{
|
||||||
|
@ -297,7 +297,7 @@ class DataSeries
|
||||||
*
|
*
|
||||||
* @param null|string $plotStyle
|
* @param null|string $plotStyle
|
||||||
*
|
*
|
||||||
* @return DataSeries
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPlotStyle($plotStyle)
|
public function setPlotStyle($plotStyle)
|
||||||
{
|
{
|
||||||
|
@ -360,7 +360,7 @@ class DataSeries
|
||||||
*
|
*
|
||||||
* @param bool $smoothLine
|
* @param bool $smoothLine
|
||||||
*
|
*
|
||||||
* @return DataSeries
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSmoothLine($smoothLine)
|
public function setSmoothLine($smoothLine)
|
||||||
{
|
{
|
||||||
|
|
|
@ -117,7 +117,7 @@ class DataSeriesValues
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return DataSeriesValues
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDataType($dataType)
|
public function setDataType($dataType)
|
||||||
{
|
{
|
||||||
|
@ -144,7 +144,7 @@ class DataSeriesValues
|
||||||
*
|
*
|
||||||
* @param string $dataSource
|
* @param string $dataSource
|
||||||
*
|
*
|
||||||
* @return DataSeriesValues
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDataSource($dataSource)
|
public function setDataSource($dataSource)
|
||||||
{
|
{
|
||||||
|
@ -168,7 +168,7 @@ class DataSeriesValues
|
||||||
*
|
*
|
||||||
* @param string $marker
|
* @param string $marker
|
||||||
*
|
*
|
||||||
* @return DataSeriesValues
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPointMarker($marker)
|
public function setPointMarker($marker)
|
||||||
{
|
{
|
||||||
|
@ -192,7 +192,7 @@ class DataSeriesValues
|
||||||
*
|
*
|
||||||
* @param string $formatCode
|
* @param string $formatCode
|
||||||
*
|
*
|
||||||
* @return DataSeriesValues
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFormatCode($formatCode)
|
public function setFormatCode($formatCode)
|
||||||
{
|
{
|
||||||
|
@ -275,7 +275,7 @@ class DataSeriesValues
|
||||||
*
|
*
|
||||||
* @param int $width
|
* @param int $width
|
||||||
*
|
*
|
||||||
* @return DataSeriesValues
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLineWidth($width)
|
public function setLineWidth($width)
|
||||||
{
|
{
|
||||||
|
@ -346,7 +346,7 @@ class DataSeriesValues
|
||||||
*
|
*
|
||||||
* @param array $dataValues
|
* @param array $dataValues
|
||||||
*
|
*
|
||||||
* @return DataSeriesValues
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDataValues($dataValues)
|
public function setDataValues($dataValues)
|
||||||
{
|
{
|
||||||
|
|
|
@ -91,7 +91,7 @@ class GridLines extends Properties
|
||||||
/**
|
/**
|
||||||
* Change Object State to True.
|
* Change Object State to True.
|
||||||
*
|
*
|
||||||
* @return GridLines
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function activateObject()
|
private function activateObject()
|
||||||
{
|
{
|
||||||
|
@ -229,7 +229,7 @@ class GridLines extends Properties
|
||||||
*
|
*
|
||||||
* @param float $size
|
* @param float $size
|
||||||
*
|
*
|
||||||
* @return GridLines
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setGlowSize($size)
|
private function setGlowSize($size)
|
||||||
{
|
{
|
||||||
|
@ -245,7 +245,7 @@ class GridLines extends Properties
|
||||||
* @param int $alpha
|
* @param int $alpha
|
||||||
* @param string $type
|
* @param string $type
|
||||||
*
|
*
|
||||||
* @return GridLines
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setGlowColor($color, $alpha, $type)
|
private function setGlowColor($color, $alpha, $type)
|
||||||
{
|
{
|
||||||
|
@ -305,7 +305,7 @@ class GridLines extends Properties
|
||||||
*
|
*
|
||||||
* @param int $shadow_presets
|
* @param int $shadow_presets
|
||||||
*
|
*
|
||||||
* @return GridLines
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowPresetsProperties($shadow_presets)
|
private function setShadowPresetsProperties($shadow_presets)
|
||||||
{
|
{
|
||||||
|
@ -321,7 +321,7 @@ class GridLines extends Properties
|
||||||
* @param array $properties_map
|
* @param array $properties_map
|
||||||
* @param mixed &$reference
|
* @param mixed &$reference
|
||||||
*
|
*
|
||||||
* @return GridLines
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowProperiesMapValues(array $properties_map, &$reference = null)
|
private function setShadowProperiesMapValues(array $properties_map, &$reference = null)
|
||||||
{
|
{
|
||||||
|
@ -353,7 +353,7 @@ class GridLines extends Properties
|
||||||
* @param int $alpha
|
* @param int $alpha
|
||||||
* @param string $type
|
* @param string $type
|
||||||
*
|
*
|
||||||
* @return GridLines
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowColor($color, $alpha, $type)
|
private function setShadowColor($color, $alpha, $type)
|
||||||
{
|
{
|
||||||
|
@ -375,7 +375,7 @@ class GridLines extends Properties
|
||||||
*
|
*
|
||||||
* @param float $blur
|
* @param float $blur
|
||||||
*
|
*
|
||||||
* @return GridLines
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowBlur($blur)
|
private function setShadowBlur($blur)
|
||||||
{
|
{
|
||||||
|
@ -391,7 +391,7 @@ class GridLines extends Properties
|
||||||
*
|
*
|
||||||
* @param int $angle
|
* @param int $angle
|
||||||
*
|
*
|
||||||
* @return GridLines
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowAngle($angle)
|
private function setShadowAngle($angle)
|
||||||
{
|
{
|
||||||
|
@ -407,7 +407,7 @@ class GridLines extends Properties
|
||||||
*
|
*
|
||||||
* @param float $distance
|
* @param float $distance
|
||||||
*
|
*
|
||||||
* @return GridLines
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function setShadowDistance($distance)
|
private function setShadowDistance($distance)
|
||||||
{
|
{
|
||||||
|
|
|
@ -153,7 +153,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLayoutTarget($value)
|
public function setLayoutTarget($value)
|
||||||
{
|
{
|
||||||
|
@ -177,7 +177,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setXMode($value)
|
public function setXMode($value)
|
||||||
{
|
{
|
||||||
|
@ -201,7 +201,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setYMode($value)
|
public function setYMode($value)
|
||||||
{
|
{
|
||||||
|
@ -225,7 +225,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param float $value
|
* @param float $value
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setXPosition($value)
|
public function setXPosition($value)
|
||||||
{
|
{
|
||||||
|
@ -249,7 +249,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param float $value
|
* @param float $value
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setYPosition($value)
|
public function setYPosition($value)
|
||||||
{
|
{
|
||||||
|
@ -273,7 +273,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param float $value
|
* @param float $value
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWidth($value)
|
public function setWidth($value)
|
||||||
{
|
{
|
||||||
|
@ -297,7 +297,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param float $value
|
* @param float $value
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setHeight($value)
|
public function setHeight($value)
|
||||||
{
|
{
|
||||||
|
@ -322,7 +322,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param bool $value Show legend key
|
* @param bool $value Show legend key
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowLegendKey($value)
|
public function setShowLegendKey($value)
|
||||||
{
|
{
|
||||||
|
@ -347,7 +347,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param bool $value Show val
|
* @param bool $value Show val
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowVal($value)
|
public function setShowVal($value)
|
||||||
{
|
{
|
||||||
|
@ -372,7 +372,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param bool $value Show cat name
|
* @param bool $value Show cat name
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowCatName($value)
|
public function setShowCatName($value)
|
||||||
{
|
{
|
||||||
|
@ -397,7 +397,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param bool $value Show series name
|
* @param bool $value Show series name
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowSerName($value)
|
public function setShowSerName($value)
|
||||||
{
|
{
|
||||||
|
@ -422,7 +422,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param bool $value Show percentage
|
* @param bool $value Show percentage
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowPercent($value)
|
public function setShowPercent($value)
|
||||||
{
|
{
|
||||||
|
@ -447,7 +447,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param bool $value Show bubble size
|
* @param bool $value Show bubble size
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowBubbleSize($value)
|
public function setShowBubbleSize($value)
|
||||||
{
|
{
|
||||||
|
@ -472,7 +472,7 @@ class Layout
|
||||||
*
|
*
|
||||||
* @param bool $value Show leader lines
|
* @param bool $value Show leader lines
|
||||||
*
|
*
|
||||||
* @return Layout
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowLeaderLines($value)
|
public function setShowLeaderLines($value)
|
||||||
{
|
{
|
||||||
|
|
|
@ -94,7 +94,7 @@ class PlotArea
|
||||||
*
|
*
|
||||||
* @param DataSeries[] $plotSeries
|
* @param DataSeries[] $plotSeries
|
||||||
*
|
*
|
||||||
* @return PlotArea
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPlotSeries(array $plotSeries)
|
public function setPlotSeries(array $plotSeries)
|
||||||
{
|
{
|
||||||
|
|
|
@ -45,7 +45,7 @@ class Title
|
||||||
*
|
*
|
||||||
* @param string $caption
|
* @param string $caption
|
||||||
*
|
*
|
||||||
* @return Title
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCaption($caption)
|
public function setCaption($caption)
|
||||||
{
|
{
|
||||||
|
|
|
@ -96,7 +96,7 @@ class Comment implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $author
|
* @param string $author
|
||||||
*
|
*
|
||||||
* @return Comment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAuthor($author)
|
public function setAuthor($author)
|
||||||
{
|
{
|
||||||
|
@ -120,7 +120,7 @@ class Comment implements IComparable
|
||||||
*
|
*
|
||||||
* @param RichText $pValue
|
* @param RichText $pValue
|
||||||
*
|
*
|
||||||
* @return Comment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setText(RichText $pValue)
|
public function setText(RichText $pValue)
|
||||||
{
|
{
|
||||||
|
@ -144,7 +144,7 @@ class Comment implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $width
|
* @param string $width
|
||||||
*
|
*
|
||||||
* @return Comment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWidth($width)
|
public function setWidth($width)
|
||||||
{
|
{
|
||||||
|
@ -168,7 +168,7 @@ class Comment implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return Comment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setHeight($value)
|
public function setHeight($value)
|
||||||
{
|
{
|
||||||
|
@ -192,7 +192,7 @@ class Comment implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return Comment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setMarginLeft($value)
|
public function setMarginLeft($value)
|
||||||
{
|
{
|
||||||
|
@ -216,7 +216,7 @@ class Comment implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return Comment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setMarginTop($value)
|
public function setMarginTop($value)
|
||||||
{
|
{
|
||||||
|
@ -240,7 +240,7 @@ class Comment implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $value
|
* @param bool $value
|
||||||
*
|
*
|
||||||
* @return Comment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setVisible($value)
|
public function setVisible($value)
|
||||||
{
|
{
|
||||||
|
@ -264,7 +264,7 @@ class Comment implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $alignment see Style\Alignment::HORIZONTAL_*
|
* @param string $alignment see Style\Alignment::HORIZONTAL_*
|
||||||
*
|
*
|
||||||
* @return Comment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAlignment($alignment)
|
public function setAlignment($alignment)
|
||||||
{
|
{
|
||||||
|
|
|
@ -122,7 +122,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param string $creator
|
* @param string $creator
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCreator($creator)
|
public function setCreator($creator)
|
||||||
{
|
{
|
||||||
|
@ -146,7 +146,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLastModifiedBy($pValue)
|
public function setLastModifiedBy($pValue)
|
||||||
{
|
{
|
||||||
|
@ -170,7 +170,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param int|string $time
|
* @param int|string $time
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCreated($time)
|
public function setCreated($time)
|
||||||
{
|
{
|
||||||
|
@ -204,7 +204,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param int|string $time
|
* @param int|string $time
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setModified($time)
|
public function setModified($time)
|
||||||
{
|
{
|
||||||
|
@ -238,7 +238,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param string $title
|
* @param string $title
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setTitle($title)
|
public function setTitle($title)
|
||||||
{
|
{
|
||||||
|
@ -262,7 +262,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param string $description
|
* @param string $description
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDescription($description)
|
public function setDescription($description)
|
||||||
{
|
{
|
||||||
|
@ -286,7 +286,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param string $subject
|
* @param string $subject
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSubject($subject)
|
public function setSubject($subject)
|
||||||
{
|
{
|
||||||
|
@ -310,7 +310,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param string $keywords
|
* @param string $keywords
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setKeywords($keywords)
|
public function setKeywords($keywords)
|
||||||
{
|
{
|
||||||
|
@ -334,7 +334,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param string $category
|
* @param string $category
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCategory($category)
|
public function setCategory($category)
|
||||||
{
|
{
|
||||||
|
@ -358,7 +358,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param string $company
|
* @param string $company
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCompany($company)
|
public function setCompany($company)
|
||||||
{
|
{
|
||||||
|
@ -382,7 +382,7 @@ class Properties
|
||||||
*
|
*
|
||||||
* @param string $manager
|
* @param string $manager
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setManager($manager)
|
public function setManager($manager)
|
||||||
{
|
{
|
||||||
|
@ -453,7 +453,7 @@ class Properties
|
||||||
* 'd' : Date/Time
|
* 'd' : Date/Time
|
||||||
* 'b' : Boolean
|
* 'b' : Boolean
|
||||||
*
|
*
|
||||||
* @return Properties
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCustomProperty($propertyName, $propertyValue = '', $propertyType = null)
|
public function setCustomProperty($propertyName, $propertyValue = '', $propertyType = null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -75,7 +75,7 @@ class Security
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Security
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLockRevision($pValue)
|
public function setLockRevision($pValue)
|
||||||
{
|
{
|
||||||
|
@ -99,7 +99,7 @@ class Security
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Security
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLockStructure($pValue)
|
public function setLockStructure($pValue)
|
||||||
{
|
{
|
||||||
|
@ -123,7 +123,7 @@ class Security
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Security
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLockWindows($pValue)
|
public function setLockWindows($pValue)
|
||||||
{
|
{
|
||||||
|
@ -148,7 +148,7 @@ class Security
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
* @param bool $pAlreadyHashed If the password has already been hashed, set this to true
|
* @param bool $pAlreadyHashed If the password has already been hashed, set this to true
|
||||||
*
|
*
|
||||||
* @return Security
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRevisionsPassword($pValue, $pAlreadyHashed = false)
|
public function setRevisionsPassword($pValue, $pAlreadyHashed = false)
|
||||||
{
|
{
|
||||||
|
@ -176,7 +176,7 @@ class Security
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
* @param bool $pAlreadyHashed If the password has already been hashed, set this to true
|
* @param bool $pAlreadyHashed If the password has already been hashed, set this to true
|
||||||
*
|
*
|
||||||
* @return Security
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWorkbookPassword($pValue, $pAlreadyHashed = false)
|
public function setWorkbookPassword($pValue, $pAlreadyHashed = false)
|
||||||
{
|
{
|
||||||
|
|
|
@ -0,0 +1,111 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
namespace PhpOffice\PhpSpreadsheet;
|
||||||
|
|
||||||
|
use PhpOffice\PhpSpreadsheet\Calculation\Category;
|
||||||
|
use PhpOffice\PhpSpreadsheet\Calculation\Functions;
|
||||||
|
use ReflectionClass;
|
||||||
|
use ReflectionException;
|
||||||
|
use UnexpectedValueException;
|
||||||
|
|
||||||
|
class DocumentGenerator
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* @param array[] $phpSpreadsheetFunctions
|
||||||
|
*
|
||||||
|
* @throws ReflectionException
|
||||||
|
*
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
public static function generateFunctionListByCategory(array $phpSpreadsheetFunctions): string
|
||||||
|
{
|
||||||
|
$result = "# Function list by category\n";
|
||||||
|
foreach (self::getCategories() as $categoryConstant => $category) {
|
||||||
|
$result .= "\n";
|
||||||
|
$result .= "## {$categoryConstant}\n";
|
||||||
|
$result .= "\n";
|
||||||
|
$lengths = [20, 42];
|
||||||
|
$result .= self::tableRow($lengths, ['Excel Function', 'PhpSpreadsheet Function']) . "\n";
|
||||||
|
$result .= self::tableRow($lengths, null) . "\n";
|
||||||
|
foreach ($phpSpreadsheetFunctions as $excelFunction => $functionInfo) {
|
||||||
|
if ($category === $functionInfo['category']) {
|
||||||
|
$phpFunction = self::getPhpSpreadsheetFunctionText($functionInfo['functionCall']);
|
||||||
|
$result .= self::tableRow($lengths, [$excelFunction, $phpFunction]) . "\n";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return $result;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @throws ReflectionException
|
||||||
|
*
|
||||||
|
* @return array
|
||||||
|
*/
|
||||||
|
private static function getCategories(): array
|
||||||
|
{
|
||||||
|
return (new ReflectionClass(Category::class))->getConstants();
|
||||||
|
}
|
||||||
|
|
||||||
|
private static function tableRow(array $lengths, array $values = null): string
|
||||||
|
{
|
||||||
|
$result = '';
|
||||||
|
foreach (array_map(null, $lengths, $values ?? []) as $i => [$length, $value]) {
|
||||||
|
$pad = $value === null ? '-' : ' ';
|
||||||
|
if ($i > 0) {
|
||||||
|
$result .= '|' . $pad;
|
||||||
|
}
|
||||||
|
$result .= str_pad($value ?? '', $length, $pad);
|
||||||
|
}
|
||||||
|
|
||||||
|
return rtrim($result, ' ');
|
||||||
|
}
|
||||||
|
|
||||||
|
private static function getPhpSpreadsheetFunctionText($functionCall): string
|
||||||
|
{
|
||||||
|
if (is_string($functionCall)) {
|
||||||
|
return $functionCall;
|
||||||
|
}
|
||||||
|
if ($functionCall === [Functions::class, 'DUMMY']) {
|
||||||
|
return '**Not yet Implemented**';
|
||||||
|
}
|
||||||
|
if (is_array($functionCall)) {
|
||||||
|
return "\\{$functionCall[0]}::{$functionCall[1]}";
|
||||||
|
}
|
||||||
|
|
||||||
|
throw new UnexpectedValueException(
|
||||||
|
'$functionCall is of type ' . gettype($functionCall) . '. string or array expected'
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param array[] $phpSpreadsheetFunctions
|
||||||
|
*
|
||||||
|
* @throws ReflectionException
|
||||||
|
*
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
public static function generateFunctionListByName(array $phpSpreadsheetFunctions): string
|
||||||
|
{
|
||||||
|
$categoryConstants = array_flip(self::getCategories());
|
||||||
|
$result = "# Function list by name\n";
|
||||||
|
$lastAlphabet = null;
|
||||||
|
foreach ($phpSpreadsheetFunctions as $excelFunction => $functionInfo) {
|
||||||
|
$lengths = [20, 31, 42];
|
||||||
|
if ($lastAlphabet !== $excelFunction[0]) {
|
||||||
|
$lastAlphabet = $excelFunction[0];
|
||||||
|
$result .= "\n";
|
||||||
|
$result .= "## {$lastAlphabet}\n";
|
||||||
|
$result .= "\n";
|
||||||
|
$result .= self::tableRow($lengths, ['Excel Function', 'Category', 'PhpSpreadsheet Function']) . "\n";
|
||||||
|
$result .= self::tableRow($lengths, null) . "\n";
|
||||||
|
}
|
||||||
|
$category = $categoryConstants[$functionInfo['category']];
|
||||||
|
$phpFunction = self::getPhpSpreadsheetFunctionText($functionInfo['functionCall']);
|
||||||
|
$result .= self::tableRow($lengths, [$excelFunction, $category, $phpFunction]) . "\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
return $result;
|
||||||
|
}
|
||||||
|
}
|
|
@ -82,7 +82,7 @@ class NamedRange
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return NamedRange
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setName($value)
|
public function setName($value)
|
||||||
{
|
{
|
||||||
|
@ -123,7 +123,7 @@ class NamedRange
|
||||||
*
|
*
|
||||||
* @param Worksheet $value
|
* @param Worksheet $value
|
||||||
*
|
*
|
||||||
* @return NamedRange
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWorksheet(Worksheet $value = null)
|
public function setWorksheet(Worksheet $value = null)
|
||||||
{
|
{
|
||||||
|
@ -149,7 +149,7 @@ class NamedRange
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return NamedRange
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRange($value)
|
public function setRange($value)
|
||||||
{
|
{
|
||||||
|
@ -175,7 +175,7 @@ class NamedRange
|
||||||
*
|
*
|
||||||
* @param bool $value
|
* @param bool $value
|
||||||
*
|
*
|
||||||
* @return NamedRange
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLocalOnly($value)
|
public function setLocalOnly($value)
|
||||||
{
|
{
|
||||||
|
@ -200,7 +200,7 @@ class NamedRange
|
||||||
*
|
*
|
||||||
* @param null|Worksheet $value
|
* @param null|Worksheet $value
|
||||||
*
|
*
|
||||||
* @return NamedRange
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setScope(Worksheet $value = null)
|
public function setScope(Worksheet $value = null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -70,7 +70,7 @@ class Csv extends BaseReader
|
||||||
*
|
*
|
||||||
* @param string $pValue Input encoding, eg: 'UTF-8'
|
* @param string $pValue Input encoding, eg: 'UTF-8'
|
||||||
*
|
*
|
||||||
* @return Csv
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setInputEncoding($pValue)
|
public function setInputEncoding($pValue)
|
||||||
{
|
{
|
||||||
|
@ -415,7 +415,7 @@ class Csv extends BaseReader
|
||||||
*
|
*
|
||||||
* @param string $delimiter Delimiter, eg: ','
|
* @param string $delimiter Delimiter, eg: ','
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDelimiter($delimiter)
|
public function setDelimiter($delimiter)
|
||||||
{
|
{
|
||||||
|
@ -439,7 +439,7 @@ class Csv extends BaseReader
|
||||||
*
|
*
|
||||||
* @param string $enclosure Enclosure, defaults to "
|
* @param string $enclosure Enclosure, defaults to "
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setEnclosure($enclosure)
|
public function setEnclosure($enclosure)
|
||||||
{
|
{
|
||||||
|
@ -466,7 +466,7 @@ class Csv extends BaseReader
|
||||||
*
|
*
|
||||||
* @param int $pValue Sheet index
|
* @param int $pValue Sheet index
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSheetIndex($pValue)
|
public function setSheetIndex($pValue)
|
||||||
{
|
{
|
||||||
|
@ -480,7 +480,7 @@ class Csv extends BaseReader
|
||||||
*
|
*
|
||||||
* @param bool $contiguous
|
* @param bool $contiguous
|
||||||
*
|
*
|
||||||
* @return Csv
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setContiguous($contiguous)
|
public function setContiguous($contiguous)
|
||||||
{
|
{
|
||||||
|
|
|
@ -223,7 +223,7 @@ class Html extends BaseReader
|
||||||
*
|
*
|
||||||
* @param string $pValue Input encoding, eg: 'ANSI'
|
* @param string $pValue Input encoding, eg: 'ANSI'
|
||||||
*
|
*
|
||||||
* @return Html
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setInputEncoding($pValue)
|
public function setInputEncoding($pValue)
|
||||||
{
|
{
|
||||||
|
@ -669,7 +669,7 @@ class Html extends BaseReader
|
||||||
*
|
*
|
||||||
* @param int $pValue Sheet index
|
* @param int $pValue Sheet index
|
||||||
*
|
*
|
||||||
* @return HTML
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSheetIndex($pValue)
|
public function setSheetIndex($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -83,7 +83,7 @@ class Slk extends BaseReader
|
||||||
*
|
*
|
||||||
* @param string $pValue Input encoding, eg: 'ANSI'
|
* @param string $pValue Input encoding, eg: 'ANSI'
|
||||||
*
|
*
|
||||||
* @return Slk
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setInputEncoding($pValue)
|
public function setInputEncoding($pValue)
|
||||||
{
|
{
|
||||||
|
@ -485,7 +485,7 @@ class Slk extends BaseReader
|
||||||
*
|
*
|
||||||
* @param int $pValue Sheet index
|
* @param int $pValue Sheet index
|
||||||
*
|
*
|
||||||
* @return Slk
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSheetIndex($pValue)
|
public function setSheetIndex($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1620,8 +1620,6 @@ class Xlsx extends BaseReader
|
||||||
$docStyle->getFill()->setFillType($patternType);
|
$docStyle->getFill()->setFillType($patternType);
|
||||||
if ($style->fill->patternFill->fgColor) {
|
if ($style->fill->patternFill->fgColor) {
|
||||||
$docStyle->getFill()->getStartColor()->setARGB(self::readColor($style->fill->patternFill->fgColor, true));
|
$docStyle->getFill()->getStartColor()->setARGB(self::readColor($style->fill->patternFill->fgColor, true));
|
||||||
} else {
|
|
||||||
$docStyle->getFill()->getStartColor()->setARGB('FF000000');
|
|
||||||
}
|
}
|
||||||
if ($style->fill->patternFill->bgColor) {
|
if ($style->fill->patternFill->bgColor) {
|
||||||
$docStyle->getFill()->getEndColor()->setARGB(self::readColor($style->fill->patternFill->bgColor, true));
|
$docStyle->getFill()->getEndColor()->setARGB(self::readColor($style->fill->patternFill->bgColor, true));
|
||||||
|
@ -1828,7 +1826,7 @@ class Xlsx extends BaseReader
|
||||||
|
|
||||||
private static function toCSSArray($style)
|
private static function toCSSArray($style)
|
||||||
{
|
{
|
||||||
$style = trim(str_replace(["\r", "\n"], '', $style), ';');
|
$style = self::stripWhiteSpaceFromStyleString($style);
|
||||||
|
|
||||||
$temp = explode(';', $style);
|
$temp = explode(';', $style);
|
||||||
$style = [];
|
$style = [];
|
||||||
|
@ -1857,6 +1855,11 @@ class Xlsx extends BaseReader
|
||||||
return $style;
|
return $style;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static function stripWhiteSpaceFromStyleString($string)
|
||||||
|
{
|
||||||
|
return trim(str_replace(["\r", "\n", ' '], '', $string), ';');
|
||||||
|
}
|
||||||
|
|
||||||
private static function boolean($value)
|
private static function boolean($value)
|
||||||
{
|
{
|
||||||
if (is_object($value)) {
|
if (is_object($value)) {
|
||||||
|
|
|
@ -20,7 +20,8 @@ class AutoFilter
|
||||||
|
|
||||||
public function load()
|
public function load()
|
||||||
{
|
{
|
||||||
$autoFilterRange = (string) $this->worksheetXml->autoFilter['ref'];
|
// Remove all "$" in the auto filter range
|
||||||
|
$autoFilterRange = preg_replace('/\$/', '', $this->worksheetXml->autoFilter['ref']);
|
||||||
if (strpos($autoFilterRange, ':') !== false) {
|
if (strpos($autoFilterRange, ':') !== false) {
|
||||||
$this->readAutoFilter($autoFilterRange, $this->worksheetXml);
|
$this->readAutoFilter($autoFilterRange, $this->worksheetXml);
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,7 +47,7 @@ class RichText implements IComparable
|
||||||
*
|
*
|
||||||
* @param ITextElement $pText Rich text element
|
* @param ITextElement $pText Rich text element
|
||||||
*
|
*
|
||||||
* @return RichText
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function addText(ITextElement $pText)
|
public function addText(ITextElement $pText)
|
||||||
{
|
{
|
||||||
|
@ -133,7 +133,7 @@ class RichText implements IComparable
|
||||||
*
|
*
|
||||||
* @param ITextElement[] $textElements Array of elements
|
* @param ITextElement[] $textElements Array of elements
|
||||||
*
|
*
|
||||||
* @return RichText
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRichTextElements(array $textElements)
|
public function setRichTextElements(array $textElements)
|
||||||
{
|
{
|
||||||
|
|
|
@ -40,7 +40,7 @@ class Run extends TextElement implements ITextElement
|
||||||
*
|
*
|
||||||
* @param Font $pFont Font
|
* @param Font $pFont Font
|
||||||
*
|
*
|
||||||
* @return ITextElement
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFont(Font $pFont = null)
|
public function setFont(Font $pFont = null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -37,7 +37,7 @@ class TextElement implements ITextElement
|
||||||
*
|
*
|
||||||
* @param $text string Text
|
* @param $text string Text
|
||||||
*
|
*
|
||||||
* @return ITextElement
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setText($text)
|
public function setText($text)
|
||||||
{
|
{
|
||||||
|
|
|
@ -28,8 +28,6 @@ class Settings
|
||||||
* Allow/disallow libxml_disable_entity_loader() call when not thread safe.
|
* Allow/disallow libxml_disable_entity_loader() call when not thread safe.
|
||||||
* Default behaviour is to do the check, but if you're running PHP versions
|
* Default behaviour is to do the check, but if you're running PHP versions
|
||||||
* 7.2 < 7.2.1
|
* 7.2 < 7.2.1
|
||||||
* 7.1 < 7.1.13
|
|
||||||
* 7.0 < 7.0.27
|
|
||||||
* then you may need to disable this check to prevent unwanted behaviour in other threads
|
* then you may need to disable this check to prevent unwanted behaviour in other threads
|
||||||
* SECURITY WARNING: Changing this flag is not recommended.
|
* SECURITY WARNING: Changing this flag is not recommended.
|
||||||
*
|
*
|
||||||
|
@ -119,8 +117,6 @@ class Settings
|
||||||
* Allow/disallow libxml_disable_entity_loader() call when not thread safe.
|
* Allow/disallow libxml_disable_entity_loader() call when not thread safe.
|
||||||
* Default behaviour is to do the check, but if you're running PHP versions
|
* Default behaviour is to do the check, but if you're running PHP versions
|
||||||
* 7.2 < 7.2.1
|
* 7.2 < 7.2.1
|
||||||
* 7.1 < 7.1.13
|
|
||||||
* 7.0 < 7.0.27
|
|
||||||
* then you may need to disable this check to prevent unwanted behaviour in other threads
|
* then you may need to disable this check to prevent unwanted behaviour in other threads
|
||||||
* SECURITY WARNING: Changing this flag to false is not recommended.
|
* SECURITY WARNING: Changing this flag to false is not recommended.
|
||||||
*
|
*
|
||||||
|
|
|
@ -524,7 +524,7 @@ class Matrix
|
||||||
*
|
*
|
||||||
* @param mixed $B Matrix/Array
|
* @param mixed $B Matrix/Array
|
||||||
*
|
*
|
||||||
* @return Matrix Sum
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function plusEquals(...$args)
|
public function plusEquals(...$args)
|
||||||
{
|
{
|
||||||
|
@ -628,7 +628,7 @@ class Matrix
|
||||||
*
|
*
|
||||||
* @param mixed $B Matrix/Array
|
* @param mixed $B Matrix/Array
|
||||||
*
|
*
|
||||||
* @return Matrix Sum
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function minusEquals(...$args)
|
public function minusEquals(...$args)
|
||||||
{
|
{
|
||||||
|
@ -734,7 +734,7 @@ class Matrix
|
||||||
*
|
*
|
||||||
* @param mixed $B Matrix/Array
|
* @param mixed $B Matrix/Array
|
||||||
*
|
*
|
||||||
* @return Matrix Matrix Aij
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function arrayTimesEquals(...$args)
|
public function arrayTimesEquals(...$args)
|
||||||
{
|
{
|
||||||
|
@ -1091,7 +1091,7 @@ class Matrix
|
||||||
*
|
*
|
||||||
* @param mixed $B Matrix/Array
|
* @param mixed $B Matrix/Array
|
||||||
*
|
*
|
||||||
* @return Matrix Sum
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function power(...$args)
|
public function power(...$args)
|
||||||
{
|
{
|
||||||
|
@ -1150,7 +1150,7 @@ class Matrix
|
||||||
*
|
*
|
||||||
* @param mixed $B Matrix/Array
|
* @param mixed $B Matrix/Array
|
||||||
*
|
*
|
||||||
* @return Matrix Sum
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function concat(...$args)
|
public function concat(...$args)
|
||||||
{
|
{
|
||||||
|
|
|
@ -955,7 +955,7 @@ class Spreadsheet
|
||||||
* @param string $namedRange
|
* @param string $namedRange
|
||||||
* @param null|Worksheet $pSheet scope: use null for global scope
|
* @param null|Worksheet $pSheet scope: use null for global scope
|
||||||
*
|
*
|
||||||
* @return Spreadsheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function removeNamedRange($namedRange, Worksheet $pSheet = null)
|
public function removeNamedRange($namedRange, Worksheet $pSheet = null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -140,7 +140,7 @@ class Alignment extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Alignment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function applyFromArray(array $pStyles)
|
public function applyFromArray(array $pStyles)
|
||||||
{
|
{
|
||||||
|
@ -193,7 +193,7 @@ class Alignment extends Supervisor
|
||||||
*
|
*
|
||||||
* @param string $pValue see self::HORIZONTAL_*
|
* @param string $pValue see self::HORIZONTAL_*
|
||||||
*
|
*
|
||||||
* @return Alignment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setHorizontal($pValue)
|
public function setHorizontal($pValue)
|
||||||
{
|
{
|
||||||
|
@ -230,7 +230,7 @@ class Alignment extends Supervisor
|
||||||
*
|
*
|
||||||
* @param string $pValue see self::VERTICAL_*
|
* @param string $pValue see self::VERTICAL_*
|
||||||
*
|
*
|
||||||
* @return Alignment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setVertical($pValue)
|
public function setVertical($pValue)
|
||||||
{
|
{
|
||||||
|
@ -269,7 +269,7 @@ class Alignment extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Alignment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setTextRotation($pValue)
|
public function setTextRotation($pValue)
|
||||||
{
|
{
|
||||||
|
@ -312,7 +312,7 @@ class Alignment extends Supervisor
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Alignment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWrapText($pValue)
|
public function setWrapText($pValue)
|
||||||
{
|
{
|
||||||
|
@ -348,7 +348,7 @@ class Alignment extends Supervisor
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Alignment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShrinkToFit($pValue)
|
public function setShrinkToFit($pValue)
|
||||||
{
|
{
|
||||||
|
@ -384,7 +384,7 @@ class Alignment extends Supervisor
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return Alignment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setIndent($pValue)
|
public function setIndent($pValue)
|
||||||
{
|
{
|
||||||
|
@ -424,7 +424,7 @@ class Alignment extends Supervisor
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return Alignment
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setReadOrder($pValue)
|
public function setReadOrder($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -127,7 +127,7 @@ class Border extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Border
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function applyFromArray(array $pStyles)
|
public function applyFromArray(array $pStyles)
|
||||||
{
|
{
|
||||||
|
@ -166,7 +166,7 @@ class Border extends Supervisor
|
||||||
* When passing a boolean, FALSE equates Border::BORDER_NONE
|
* When passing a boolean, FALSE equates Border::BORDER_NONE
|
||||||
* and TRUE to Border::BORDER_MEDIUM
|
* and TRUE to Border::BORDER_MEDIUM
|
||||||
*
|
*
|
||||||
* @return Border
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setBorderStyle($pValue)
|
public function setBorderStyle($pValue)
|
||||||
{
|
{
|
||||||
|
@ -202,7 +202,7 @@ class Border extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Border
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setColor(Color $pValue)
|
public function setColor(Color $pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -197,7 +197,7 @@ class Borders extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Borders
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function applyFromArray(array $pStyles)
|
public function applyFromArray(array $pStyles)
|
||||||
{
|
{
|
||||||
|
@ -382,7 +382,7 @@ class Borders extends Supervisor
|
||||||
*
|
*
|
||||||
* @param int $pValue see self::DIAGONAL_*
|
* @param int $pValue see self::DIAGONAL_*
|
||||||
*
|
*
|
||||||
* @return Borders
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDiagonalDirection($pValue)
|
public function setDiagonalDirection($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -106,7 +106,7 @@ class Color extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Color
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function applyFromArray(array $pStyles)
|
public function applyFromArray(array $pStyles)
|
||||||
{
|
{
|
||||||
|
@ -143,7 +143,7 @@ class Color extends Supervisor
|
||||||
*
|
*
|
||||||
* @param string $pValue see self::COLOR_*
|
* @param string $pValue see self::COLOR_*
|
||||||
*
|
*
|
||||||
* @return Color
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setARGB($pValue)
|
public function setARGB($pValue)
|
||||||
{
|
{
|
||||||
|
@ -179,7 +179,7 @@ class Color extends Supervisor
|
||||||
*
|
*
|
||||||
* @param string $pValue RGB value
|
* @param string $pValue RGB value
|
||||||
*
|
*
|
||||||
* @return Color
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRGB($pValue)
|
public function setRGB($pValue)
|
||||||
{
|
{
|
||||||
|
@ -312,7 +312,7 @@ class Color extends Supervisor
|
||||||
* @param bool $background Flag to indicate whether default background or foreground colour
|
* @param bool $background Flag to indicate whether default background or foreground colour
|
||||||
* should be returned if the indexed colour doesn't exist
|
* should be returned if the indexed colour doesn't exist
|
||||||
*
|
*
|
||||||
* @return Color
|
* @return self
|
||||||
*/
|
*/
|
||||||
public static function indexedColor($pIndex, $background = false)
|
public static function indexedColor($pIndex, $background = false)
|
||||||
{
|
{
|
||||||
|
|
|
@ -27,6 +27,7 @@ class Conditional implements IComparable
|
||||||
const OPERATOR_CONTAINSTEXT = 'containsText';
|
const OPERATOR_CONTAINSTEXT = 'containsText';
|
||||||
const OPERATOR_NOTCONTAINS = 'notContains';
|
const OPERATOR_NOTCONTAINS = 'notContains';
|
||||||
const OPERATOR_BETWEEN = 'between';
|
const OPERATOR_BETWEEN = 'between';
|
||||||
|
const OPERATOR_NOTBETWEEN = 'notBetween';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Condition type.
|
* Condition type.
|
||||||
|
@ -94,7 +95,7 @@ class Conditional implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $pValue Condition type, see self::CONDITION_*
|
* @param string $pValue Condition type, see self::CONDITION_*
|
||||||
*
|
*
|
||||||
* @return Conditional
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setConditionType($pValue)
|
public function setConditionType($pValue)
|
||||||
{
|
{
|
||||||
|
@ -118,7 +119,7 @@ class Conditional implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $pValue Conditional operator type, see self::OPERATOR_*
|
* @param string $pValue Conditional operator type, see self::OPERATOR_*
|
||||||
*
|
*
|
||||||
* @return Conditional
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOperatorType($pValue)
|
public function setOperatorType($pValue)
|
||||||
{
|
{
|
||||||
|
@ -142,7 +143,7 @@ class Conditional implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $value
|
* @param string $value
|
||||||
*
|
*
|
||||||
* @return Conditional
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setText($value)
|
public function setText($value)
|
||||||
{
|
{
|
||||||
|
@ -166,7 +167,7 @@ class Conditional implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $value
|
* @param bool $value
|
||||||
*
|
*
|
||||||
* @return Conditional
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setStopIfTrue($value)
|
public function setStopIfTrue($value)
|
||||||
{
|
{
|
||||||
|
@ -190,7 +191,7 @@ class Conditional implements IComparable
|
||||||
*
|
*
|
||||||
* @param string[] $pValue Condition
|
* @param string[] $pValue Condition
|
||||||
*
|
*
|
||||||
* @return Conditional
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setConditions($pValue)
|
public function setConditions($pValue)
|
||||||
{
|
{
|
||||||
|
@ -207,7 +208,7 @@ class Conditional implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $pValue Condition
|
* @param string $pValue Condition
|
||||||
*
|
*
|
||||||
* @return Conditional
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function addCondition($pValue)
|
public function addCondition($pValue)
|
||||||
{
|
{
|
||||||
|
@ -231,7 +232,7 @@ class Conditional implements IComparable
|
||||||
*
|
*
|
||||||
* @param Style $pValue
|
* @param Style $pValue
|
||||||
*
|
*
|
||||||
* @return Conditional
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setStyle(Style $pValue = null)
|
public function setStyle(Style $pValue = null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -141,7 +141,7 @@ class Fill extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Fill
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function applyFromArray(array $pStyles)
|
public function applyFromArray(array $pStyles)
|
||||||
{
|
{
|
||||||
|
@ -188,7 +188,7 @@ class Fill extends Supervisor
|
||||||
*
|
*
|
||||||
* @param string $pValue Fill type, see self::FILL_*
|
* @param string $pValue Fill type, see self::FILL_*
|
||||||
*
|
*
|
||||||
* @return Fill
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFillType($pValue)
|
public function setFillType($pValue)
|
||||||
{
|
{
|
||||||
|
@ -221,7 +221,7 @@ class Fill extends Supervisor
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return Fill
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRotation($pValue)
|
public function setRotation($pValue)
|
||||||
{
|
{
|
||||||
|
@ -252,7 +252,7 @@ class Fill extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Fill
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setStartColor(Color $pValue)
|
public function setStartColor(Color $pValue)
|
||||||
{
|
{
|
||||||
|
@ -286,7 +286,7 @@ class Fill extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Fill
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setEndColor(Color $pValue)
|
public function setEndColor(Color $pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -161,7 +161,7 @@ class Font extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function applyFromArray(array $pStyles)
|
public function applyFromArray(array $pStyles)
|
||||||
{
|
{
|
||||||
|
@ -219,7 +219,7 @@ class Font extends Supervisor
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setName($pValue)
|
public function setName($pValue)
|
||||||
{
|
{
|
||||||
|
@ -255,7 +255,7 @@ class Font extends Supervisor
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSize($pValue)
|
public function setSize($pValue)
|
||||||
{
|
{
|
||||||
|
@ -291,7 +291,7 @@ class Font extends Supervisor
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setBold($pValue)
|
public function setBold($pValue)
|
||||||
{
|
{
|
||||||
|
@ -327,7 +327,7 @@ class Font extends Supervisor
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setItalic($pValue)
|
public function setItalic($pValue)
|
||||||
{
|
{
|
||||||
|
@ -363,7 +363,7 @@ class Font extends Supervisor
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSuperscript($pValue)
|
public function setSuperscript($pValue)
|
||||||
{
|
{
|
||||||
|
@ -400,7 +400,7 @@ class Font extends Supervisor
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSubscript($pValue)
|
public function setSubscript($pValue)
|
||||||
{
|
{
|
||||||
|
@ -439,7 +439,7 @@ class Font extends Supervisor
|
||||||
* If a boolean is passed, then TRUE equates to UNDERLINE_SINGLE,
|
* If a boolean is passed, then TRUE equates to UNDERLINE_SINGLE,
|
||||||
* false equates to UNDERLINE_NONE
|
* false equates to UNDERLINE_NONE
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setUnderline($pValue)
|
public function setUnderline($pValue)
|
||||||
{
|
{
|
||||||
|
@ -477,7 +477,7 @@ class Font extends Supervisor
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setStrikethrough($pValue)
|
public function setStrikethrough($pValue)
|
||||||
{
|
{
|
||||||
|
@ -512,7 +512,7 @@ class Font extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Font
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setColor(Color $pValue)
|
public function setColor(Color $pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -139,7 +139,7 @@ class NumberFormat extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return NumberFormat
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function applyFromArray(array $pStyles)
|
public function applyFromArray(array $pStyles)
|
||||||
{
|
{
|
||||||
|
@ -176,7 +176,7 @@ class NumberFormat extends Supervisor
|
||||||
*
|
*
|
||||||
* @param string $pValue see self::FORMAT_*
|
* @param string $pValue see self::FORMAT_*
|
||||||
*
|
*
|
||||||
* @return NumberFormat
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFormatCode($pValue)
|
public function setFormatCode($pValue)
|
||||||
{
|
{
|
||||||
|
@ -213,7 +213,7 @@ class NumberFormat extends Supervisor
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return NumberFormat
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setBuiltInFormatCode($pValue)
|
public function setBuiltInFormatCode($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -86,7 +86,7 @@ class Protection extends Supervisor
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function applyFromArray(array $pStyles)
|
public function applyFromArray(array $pStyles)
|
||||||
{
|
{
|
||||||
|
@ -123,7 +123,7 @@ class Protection extends Supervisor
|
||||||
*
|
*
|
||||||
* @param string $pValue see self::PROTECTION_*
|
* @param string $pValue see self::PROTECTION_*
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLocked($pValue)
|
public function setLocked($pValue)
|
||||||
{
|
{
|
||||||
|
@ -156,7 +156,7 @@ class Protection extends Supervisor
|
||||||
*
|
*
|
||||||
* @param string $pValue see self::PROTECTION_*
|
* @param string $pValue see self::PROTECTION_*
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setHidden($pValue)
|
public function setHidden($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -189,7 +189,7 @@ class Style extends Supervisor
|
||||||
* @param array $pStyles Array containing style information
|
* @param array $pStyles Array containing style information
|
||||||
* @param bool $pAdvanced advanced mode for setting borders
|
* @param bool $pAdvanced advanced mode for setting borders
|
||||||
*
|
*
|
||||||
* @return Style
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function applyFromArray(array $pStyles, $pAdvanced = true)
|
public function applyFromArray(array $pStyles, $pAdvanced = true)
|
||||||
{
|
{
|
||||||
|
@ -485,7 +485,7 @@ class Style extends Supervisor
|
||||||
*
|
*
|
||||||
* @param Font $font
|
* @param Font $font
|
||||||
*
|
*
|
||||||
* @return Style
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFont(Font $font)
|
public function setFont(Font $font)
|
||||||
{
|
{
|
||||||
|
@ -539,7 +539,7 @@ class Style extends Supervisor
|
||||||
*
|
*
|
||||||
* @param Conditional[] $pValue Array of conditional styles
|
* @param Conditional[] $pValue Array of conditional styles
|
||||||
*
|
*
|
||||||
* @return Style
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setConditionalStyles(array $pValue)
|
public function setConditionalStyles(array $pValue)
|
||||||
{
|
{
|
||||||
|
@ -577,7 +577,7 @@ class Style extends Supervisor
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Style
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setQuotePrefix($pValue)
|
public function setQuotePrefix($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -48,7 +48,7 @@ abstract class Supervisor implements IComparable
|
||||||
* @param Spreadsheet|Style $parent
|
* @param Spreadsheet|Style $parent
|
||||||
* @param null|string $parentPropertyName
|
* @param null|string $parentPropertyName
|
||||||
*
|
*
|
||||||
* @return Supervisor
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function bindParent($parent, $parentPropertyName = null)
|
public function bindParent($parent, $parentPropertyName = null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -59,7 +59,7 @@ class AutoFilter
|
||||||
*
|
*
|
||||||
* @param Worksheet $pSheet
|
* @param Worksheet $pSheet
|
||||||
*
|
*
|
||||||
* @return AutoFilter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setParent(Worksheet $pSheet = null)
|
public function setParent(Worksheet $pSheet = null)
|
||||||
{
|
{
|
||||||
|
@ -85,7 +85,7 @@ class AutoFilter
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return AutoFilter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRange($pRange)
|
public function setRange($pRange)
|
||||||
{
|
{
|
||||||
|
@ -210,7 +210,7 @@ class AutoFilter
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return AutoFilter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setColumn($pColumn)
|
public function setColumn($pColumn)
|
||||||
{
|
{
|
||||||
|
@ -241,7 +241,7 @@ class AutoFilter
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return AutoFilter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function clearColumn($pColumn)
|
public function clearColumn($pColumn)
|
||||||
{
|
{
|
||||||
|
@ -264,7 +264,7 @@ class AutoFilter
|
||||||
* @param string $fromColumn Column name (e.g. A)
|
* @param string $fromColumn Column name (e.g. A)
|
||||||
* @param string $toColumn Column name (e.g. B)
|
* @param string $toColumn Column name (e.g. B)
|
||||||
*
|
*
|
||||||
* @return AutoFilter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function shiftColumn($fromColumn, $toColumn)
|
public function shiftColumn($fromColumn, $toColumn)
|
||||||
{
|
{
|
||||||
|
@ -617,7 +617,7 @@ class AutoFilter
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return AutoFilter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function showHideRows()
|
public function showHideRows()
|
||||||
{
|
{
|
||||||
|
|
|
@ -117,7 +117,7 @@ class Column
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Column
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setColumnIndex($pColumn)
|
public function setColumnIndex($pColumn)
|
||||||
{
|
{
|
||||||
|
@ -147,7 +147,7 @@ class Column
|
||||||
*
|
*
|
||||||
* @param AutoFilter $pParent
|
* @param AutoFilter $pParent
|
||||||
*
|
*
|
||||||
* @return Column
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setParent(AutoFilter $pParent = null)
|
public function setParent(AutoFilter $pParent = null)
|
||||||
{
|
{
|
||||||
|
@ -173,7 +173,7 @@ class Column
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Column
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFilterType($pFilterType)
|
public function setFilterType($pFilterType)
|
||||||
{
|
{
|
||||||
|
@ -203,7 +203,7 @@ class Column
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Column
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setJoin($pJoin)
|
public function setJoin($pJoin)
|
||||||
{
|
{
|
||||||
|
@ -223,7 +223,7 @@ class Column
|
||||||
*
|
*
|
||||||
* @param string[] $attributes
|
* @param string[] $attributes
|
||||||
*
|
*
|
||||||
* @return Column
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAttributes(array $attributes)
|
public function setAttributes(array $attributes)
|
||||||
{
|
{
|
||||||
|
@ -238,7 +238,7 @@ class Column
|
||||||
* @param string $pName Attribute Name
|
* @param string $pName Attribute Name
|
||||||
* @param string $pValue Attribute Value
|
* @param string $pValue Attribute Value
|
||||||
*
|
*
|
||||||
* @return Column
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAttribute($pName, $pValue)
|
public function setAttribute($pName, $pValue)
|
||||||
{
|
{
|
||||||
|
@ -316,7 +316,7 @@ class Column
|
||||||
*
|
*
|
||||||
* @param Column\Rule $pRule
|
* @param Column\Rule $pRule
|
||||||
*
|
*
|
||||||
* @return Column
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function addRule(Column\Rule $pRule)
|
public function addRule(Column\Rule $pRule)
|
||||||
{
|
{
|
||||||
|
@ -332,7 +332,7 @@ class Column
|
||||||
*
|
*
|
||||||
* @param int $pIndex Rule index in the ruleset array
|
* @param int $pIndex Rule index in the ruleset array
|
||||||
*
|
*
|
||||||
* @return Column
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function deleteRule($pIndex)
|
public function deleteRule($pIndex)
|
||||||
{
|
{
|
||||||
|
@ -350,7 +350,7 @@ class Column
|
||||||
/**
|
/**
|
||||||
* Delete all AutoFilter Column Rules.
|
* Delete all AutoFilter Column Rules.
|
||||||
*
|
*
|
||||||
* @return Column
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function clearRules()
|
public function clearRules()
|
||||||
{
|
{
|
||||||
|
|
|
@ -262,7 +262,7 @@ class Rule
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Rule
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRuleType($pRuleType)
|
public function setRuleType($pRuleType)
|
||||||
{
|
{
|
||||||
|
@ -292,7 +292,7 @@ class Rule
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Rule
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setValue($pValue)
|
public function setValue($pValue)
|
||||||
{
|
{
|
||||||
|
@ -336,7 +336,7 @@ class Rule
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Rule
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOperator($pOperator)
|
public function setOperator($pOperator)
|
||||||
{
|
{
|
||||||
|
@ -369,7 +369,7 @@ class Rule
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Rule
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setGrouping($pGrouping)
|
public function setGrouping($pGrouping)
|
||||||
{
|
{
|
||||||
|
@ -393,7 +393,7 @@ class Rule
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Rule
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRule($pOperator, $pValue, $pGrouping = null)
|
public function setRule($pOperator, $pValue, $pGrouping = null)
|
||||||
{
|
{
|
||||||
|
@ -424,7 +424,7 @@ class Rule
|
||||||
*
|
*
|
||||||
* @param Column $pParent
|
* @param Column $pParent
|
||||||
*
|
*
|
||||||
* @return Rule
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setParent(Column $pParent = null)
|
public function setParent(Column $pParent = null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -154,7 +154,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setName($pValue)
|
public function setName($pValue)
|
||||||
{
|
{
|
||||||
|
@ -178,7 +178,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $description
|
* @param string $description
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDescription($description)
|
public function setDescription($description)
|
||||||
{
|
{
|
||||||
|
@ -205,7 +205,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWorksheet(Worksheet $pValue = null, $pOverrideOld = false)
|
public function setWorksheet(Worksheet $pValue = null, $pOverrideOld = false)
|
||||||
{
|
{
|
||||||
|
@ -253,7 +253,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $pValue eg: 'A1'
|
* @param string $pValue eg: 'A1'
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCoordinates($pValue)
|
public function setCoordinates($pValue)
|
||||||
{
|
{
|
||||||
|
@ -277,7 +277,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOffsetX($pValue)
|
public function setOffsetX($pValue)
|
||||||
{
|
{
|
||||||
|
@ -301,7 +301,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOffsetY($pValue)
|
public function setOffsetY($pValue)
|
||||||
{
|
{
|
||||||
|
@ -325,7 +325,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWidth($pValue)
|
public function setWidth($pValue)
|
||||||
{
|
{
|
||||||
|
@ -356,7 +356,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setHeight($pValue)
|
public function setHeight($pValue)
|
||||||
{
|
{
|
||||||
|
@ -386,7 +386,7 @@ class BaseDrawing implements IComparable
|
||||||
* @param int $width
|
* @param int $width
|
||||||
* @param int $height
|
* @param int $height
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWidthAndHeight($width, $height)
|
public function setWidthAndHeight($width, $height)
|
||||||
{
|
{
|
||||||
|
@ -423,7 +423,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setResizeProportional($pValue)
|
public function setResizeProportional($pValue)
|
||||||
{
|
{
|
||||||
|
@ -447,7 +447,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRotation($pValue)
|
public function setRotation($pValue)
|
||||||
{
|
{
|
||||||
|
@ -471,7 +471,7 @@ class BaseDrawing implements IComparable
|
||||||
*
|
*
|
||||||
* @param Drawing\Shadow $pValue
|
* @param Drawing\Shadow $pValue
|
||||||
*
|
*
|
||||||
* @return BaseDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShadow(Drawing\Shadow $pValue = null)
|
public function setShadow(Drawing\Shadow $pValue = null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -59,7 +59,7 @@ class ColumnCellIterator extends CellIterator
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return ColumnCellIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetStart($startRow = 1)
|
public function resetStart($startRow = 1)
|
||||||
{
|
{
|
||||||
|
@ -77,7 +77,7 @@ class ColumnCellIterator extends CellIterator
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return ColumnCellIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetEnd($endRow = null)
|
public function resetEnd($endRow = null)
|
||||||
{
|
{
|
||||||
|
@ -94,7 +94,7 @@ class ColumnCellIterator extends CellIterator
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return ColumnCellIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function seek($row = 1)
|
public function seek($row = 1)
|
||||||
{
|
{
|
||||||
|
|
|
@ -56,7 +56,7 @@ class ColumnDimension extends Dimension
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return ColumnDimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setColumnIndex($pValue)
|
public function setColumnIndex($pValue)
|
||||||
{
|
{
|
||||||
|
@ -80,7 +80,7 @@ class ColumnDimension extends Dimension
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return ColumnDimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setWidth($pValue)
|
public function setWidth($pValue)
|
||||||
{
|
{
|
||||||
|
@ -104,7 +104,7 @@ class ColumnDimension extends Dimension
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return ColumnDimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAutoSize($pValue)
|
public function setAutoSize($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -66,7 +66,7 @@ class ColumnIterator implements \Iterator
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return ColumnIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetStart($startColumn = 'A')
|
public function resetStart($startColumn = 'A')
|
||||||
{
|
{
|
||||||
|
@ -89,7 +89,7 @@ class ColumnIterator implements \Iterator
|
||||||
*
|
*
|
||||||
* @param string $endColumn The column address at which to stop iterating
|
* @param string $endColumn The column address at which to stop iterating
|
||||||
*
|
*
|
||||||
* @return ColumnIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetEnd($endColumn = null)
|
public function resetEnd($endColumn = null)
|
||||||
{
|
{
|
||||||
|
@ -106,7 +106,7 @@ class ColumnIterator implements \Iterator
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return ColumnIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function seek($column = 'A')
|
public function seek($column = 'A')
|
||||||
{
|
{
|
||||||
|
|
|
@ -60,7 +60,7 @@ abstract class Dimension
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Dimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setVisible($pValue)
|
public function setVisible($pValue)
|
||||||
{
|
{
|
||||||
|
@ -87,7 +87,7 @@ abstract class Dimension
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Dimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOutlineLevel($pValue)
|
public function setOutlineLevel($pValue)
|
||||||
{
|
{
|
||||||
|
@ -115,7 +115,7 @@ abstract class Dimension
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Dimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCollapsed($pValue)
|
public function setCollapsed($pValue)
|
||||||
{
|
{
|
||||||
|
@ -139,7 +139,7 @@ abstract class Dimension
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return Dimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setXfIndex($pValue)
|
public function setXfIndex($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -78,7 +78,7 @@ class Drawing extends BaseDrawing
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return Drawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPath($pValue, $pVerifyFile = true)
|
public function setPath($pValue, $pVerifyFile = true)
|
||||||
{
|
{
|
||||||
|
|
|
@ -100,7 +100,7 @@ class Shadow implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Shadow
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setVisible($pValue)
|
public function setVisible($pValue)
|
||||||
{
|
{
|
||||||
|
@ -124,7 +124,7 @@ class Shadow implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return Shadow
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setBlurRadius($pValue)
|
public function setBlurRadius($pValue)
|
||||||
{
|
{
|
||||||
|
@ -148,7 +148,7 @@ class Shadow implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return Shadow
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDistance($pValue)
|
public function setDistance($pValue)
|
||||||
{
|
{
|
||||||
|
@ -172,7 +172,7 @@ class Shadow implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return Shadow
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDirection($pValue)
|
public function setDirection($pValue)
|
||||||
{
|
{
|
||||||
|
@ -196,7 +196,7 @@ class Shadow implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return Shadow
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAlignment($pValue)
|
public function setAlignment($pValue)
|
||||||
{
|
{
|
||||||
|
@ -220,7 +220,7 @@ class Shadow implements IComparable
|
||||||
*
|
*
|
||||||
* @param Color $pValue
|
* @param Color $pValue
|
||||||
*
|
*
|
||||||
* @return Shadow
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setColor(Color $pValue = null)
|
public function setColor(Color $pValue = null)
|
||||||
{
|
{
|
||||||
|
@ -244,7 +244,7 @@ class Shadow implements IComparable
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return Shadow
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAlpha($pValue)
|
public function setAlpha($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -172,7 +172,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOddHeader($pValue)
|
public function setOddHeader($pValue)
|
||||||
{
|
{
|
||||||
|
@ -196,7 +196,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOddFooter($pValue)
|
public function setOddFooter($pValue)
|
||||||
{
|
{
|
||||||
|
@ -220,7 +220,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setEvenHeader($pValue)
|
public function setEvenHeader($pValue)
|
||||||
{
|
{
|
||||||
|
@ -244,7 +244,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setEvenFooter($pValue)
|
public function setEvenFooter($pValue)
|
||||||
{
|
{
|
||||||
|
@ -268,7 +268,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFirstHeader($pValue)
|
public function setFirstHeader($pValue)
|
||||||
{
|
{
|
||||||
|
@ -292,7 +292,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFirstFooter($pValue)
|
public function setFirstFooter($pValue)
|
||||||
{
|
{
|
||||||
|
@ -316,7 +316,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDifferentOddEven($pValue)
|
public function setDifferentOddEven($pValue)
|
||||||
{
|
{
|
||||||
|
@ -340,7 +340,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDifferentFirst($pValue)
|
public function setDifferentFirst($pValue)
|
||||||
{
|
{
|
||||||
|
@ -364,7 +364,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setScaleWithDocument($pValue)
|
public function setScaleWithDocument($pValue)
|
||||||
{
|
{
|
||||||
|
@ -388,7 +388,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAlignWithMargins($pValue)
|
public function setAlignWithMargins($pValue)
|
||||||
{
|
{
|
||||||
|
@ -403,7 +403,7 @@ class HeaderFooter
|
||||||
* @param HeaderFooterDrawing $image
|
* @param HeaderFooterDrawing $image
|
||||||
* @param string $location
|
* @param string $location
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function addImage(HeaderFooterDrawing $image, $location = self::IMAGE_HEADER_LEFT)
|
public function addImage(HeaderFooterDrawing $image, $location = self::IMAGE_HEADER_LEFT)
|
||||||
{
|
{
|
||||||
|
@ -417,7 +417,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param string $location
|
* @param string $location
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function removeImage($location = self::IMAGE_HEADER_LEFT)
|
public function removeImage($location = self::IMAGE_HEADER_LEFT)
|
||||||
{
|
{
|
||||||
|
@ -433,7 +433,7 @@ class HeaderFooter
|
||||||
*
|
*
|
||||||
* @param HeaderFooterDrawing[] $images
|
* @param HeaderFooterDrawing[] $images
|
||||||
*
|
*
|
||||||
* @return HeaderFooter
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setImages(array $images)
|
public function setImages(array $images)
|
||||||
{
|
{
|
||||||
|
|
|
@ -74,7 +74,7 @@ class MemoryDrawing extends BaseDrawing
|
||||||
*
|
*
|
||||||
* @param resource $value
|
* @param resource $value
|
||||||
*
|
*
|
||||||
* @return MemoryDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setImageResource($value)
|
public function setImageResource($value)
|
||||||
{
|
{
|
||||||
|
@ -104,7 +104,7 @@ class MemoryDrawing extends BaseDrawing
|
||||||
*
|
*
|
||||||
* @param string $value see self::RENDERING_*
|
* @param string $value see self::RENDERING_*
|
||||||
*
|
*
|
||||||
* @return MemoryDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRenderingFunction($value)
|
public function setRenderingFunction($value)
|
||||||
{
|
{
|
||||||
|
@ -128,7 +128,7 @@ class MemoryDrawing extends BaseDrawing
|
||||||
*
|
*
|
||||||
* @param string $value see self::MIMETYPE_*
|
* @param string $value see self::MIMETYPE_*
|
||||||
*
|
*
|
||||||
* @return MemoryDrawing
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setMimeType($value)
|
public function setMimeType($value)
|
||||||
{
|
{
|
||||||
|
|
|
@ -68,7 +68,7 @@ class PageMargins
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return PageMargins
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLeft($pValue)
|
public function setLeft($pValue)
|
||||||
{
|
{
|
||||||
|
@ -92,7 +92,7 @@ class PageMargins
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return PageMargins
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRight($pValue)
|
public function setRight($pValue)
|
||||||
{
|
{
|
||||||
|
@ -116,7 +116,7 @@ class PageMargins
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return PageMargins
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setTop($pValue)
|
public function setTop($pValue)
|
||||||
{
|
{
|
||||||
|
@ -140,7 +140,7 @@ class PageMargins
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return PageMargins
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setBottom($pValue)
|
public function setBottom($pValue)
|
||||||
{
|
{
|
||||||
|
@ -164,7 +164,7 @@ class PageMargins
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return PageMargins
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setHeader($pValue)
|
public function setHeader($pValue)
|
||||||
{
|
{
|
||||||
|
@ -188,7 +188,7 @@ class PageMargins
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return PageMargins
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFooter($pValue)
|
public function setFooter($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -180,7 +180,7 @@ class PageSetup
|
||||||
* Print scaling. Valid values range from 10 to 400
|
* Print scaling. Valid values range from 10 to 400
|
||||||
* This setting is overridden when fitToWidth and/or fitToHeight are in use
|
* This setting is overridden when fitToWidth and/or fitToHeight are in use
|
||||||
*
|
*
|
||||||
* @var int?
|
* @var null|int
|
||||||
*/
|
*/
|
||||||
private $scale = 100;
|
private $scale = 100;
|
||||||
|
|
||||||
|
@ -196,7 +196,7 @@ class PageSetup
|
||||||
* Fit To Height
|
* Fit To Height
|
||||||
* Number of vertical pages to fit on.
|
* Number of vertical pages to fit on.
|
||||||
*
|
*
|
||||||
* @var int?
|
* @var null|int
|
||||||
*/
|
*/
|
||||||
private $fitToHeight = 1;
|
private $fitToHeight = 1;
|
||||||
|
|
||||||
|
@ -204,7 +204,7 @@ class PageSetup
|
||||||
* Fit To Width
|
* Fit To Width
|
||||||
* Number of horizontal pages to fit on.
|
* Number of horizontal pages to fit on.
|
||||||
*
|
*
|
||||||
* @var int?
|
* @var null|int
|
||||||
*/
|
*/
|
||||||
private $fitToWidth = 1;
|
private $fitToWidth = 1;
|
||||||
|
|
||||||
|
@ -272,7 +272,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @param int $pValue see self::PAPERSIZE_*
|
* @param int $pValue see self::PAPERSIZE_*
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPaperSize($pValue)
|
public function setPaperSize($pValue)
|
||||||
{
|
{
|
||||||
|
@ -296,7 +296,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @param string $pValue see self::ORIENTATION_*
|
* @param string $pValue see self::ORIENTATION_*
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOrientation($pValue)
|
public function setOrientation($pValue)
|
||||||
{
|
{
|
||||||
|
@ -308,7 +308,7 @@ class PageSetup
|
||||||
/**
|
/**
|
||||||
* Get Scale.
|
* Get Scale.
|
||||||
*
|
*
|
||||||
* @return int?
|
* @return null|int
|
||||||
*/
|
*/
|
||||||
public function getScale()
|
public function getScale()
|
||||||
{
|
{
|
||||||
|
@ -325,7 +325,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setScale($pValue, $pUpdate = true)
|
public function setScale($pValue, $pUpdate = true)
|
||||||
{
|
{
|
||||||
|
@ -358,7 +358,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFitToPage($pValue)
|
public function setFitToPage($pValue)
|
||||||
{
|
{
|
||||||
|
@ -370,7 +370,7 @@ class PageSetup
|
||||||
/**
|
/**
|
||||||
* Get Fit To Height.
|
* Get Fit To Height.
|
||||||
*
|
*
|
||||||
* @return int?
|
* @return null|int
|
||||||
*/
|
*/
|
||||||
public function getFitToHeight()
|
public function getFitToHeight()
|
||||||
{
|
{
|
||||||
|
@ -383,7 +383,7 @@ class PageSetup
|
||||||
* @param null|int $pValue
|
* @param null|int $pValue
|
||||||
* @param bool $pUpdate Update fitToPage so it applies rather than scaling
|
* @param bool $pUpdate Update fitToPage so it applies rather than scaling
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFitToHeight($pValue, $pUpdate = true)
|
public function setFitToHeight($pValue, $pUpdate = true)
|
||||||
{
|
{
|
||||||
|
@ -398,7 +398,7 @@ class PageSetup
|
||||||
/**
|
/**
|
||||||
* Get Fit To Width.
|
* Get Fit To Width.
|
||||||
*
|
*
|
||||||
* @return int?
|
* @return null|int
|
||||||
*/
|
*/
|
||||||
public function getFitToWidth()
|
public function getFitToWidth()
|
||||||
{
|
{
|
||||||
|
@ -411,7 +411,7 @@ class PageSetup
|
||||||
* @param null|int $pValue
|
* @param null|int $pValue
|
||||||
* @param bool $pUpdate Update fitToPage so it applies rather than scaling
|
* @param bool $pUpdate Update fitToPage so it applies rather than scaling
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFitToWidth($pValue, $pUpdate = true)
|
public function setFitToWidth($pValue, $pUpdate = true)
|
||||||
{
|
{
|
||||||
|
@ -454,7 +454,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @param array $pValue Containing start column and end column, empty array if option unset
|
* @param array $pValue Containing start column and end column, empty array if option unset
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setColumnsToRepeatAtLeft(array $pValue)
|
public function setColumnsToRepeatAtLeft(array $pValue)
|
||||||
{
|
{
|
||||||
|
@ -469,7 +469,7 @@ class PageSetup
|
||||||
* @param string $pStart eg: 'A'
|
* @param string $pStart eg: 'A'
|
||||||
* @param string $pEnd eg: 'B'
|
* @param string $pEnd eg: 'B'
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setColumnsToRepeatAtLeftByStartAndEnd($pStart, $pEnd)
|
public function setColumnsToRepeatAtLeftByStartAndEnd($pStart, $pEnd)
|
||||||
{
|
{
|
||||||
|
@ -509,7 +509,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @param array $pValue Containing start column and end column, empty array if option unset
|
* @param array $pValue Containing start column and end column, empty array if option unset
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRowsToRepeatAtTop(array $pValue)
|
public function setRowsToRepeatAtTop(array $pValue)
|
||||||
{
|
{
|
||||||
|
@ -524,7 +524,7 @@ class PageSetup
|
||||||
* @param int $pStart eg: 1
|
* @param int $pStart eg: 1
|
||||||
* @param int $pEnd eg: 1
|
* @param int $pEnd eg: 1
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRowsToRepeatAtTopByStartAndEnd($pStart, $pEnd)
|
public function setRowsToRepeatAtTopByStartAndEnd($pStart, $pEnd)
|
||||||
{
|
{
|
||||||
|
@ -548,7 +548,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @param bool $value
|
* @param bool $value
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setHorizontalCentered($value)
|
public function setHorizontalCentered($value)
|
||||||
{
|
{
|
||||||
|
@ -572,7 +572,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @param bool $value
|
* @param bool $value
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setVerticalCentered($value)
|
public function setVerticalCentered($value)
|
||||||
{
|
{
|
||||||
|
@ -634,7 +634,7 @@ class PageSetup
|
||||||
* Otherwise, the range identified by the value of $index will be removed from the series
|
* Otherwise, the range identified by the value of $index will be removed from the series
|
||||||
* Print areas are numbered from 1
|
* Print areas are numbered from 1
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function clearPrintArea($index = 0)
|
public function clearPrintArea($index = 0)
|
||||||
{
|
{
|
||||||
|
@ -671,7 +671,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPrintArea($value, $index = 0, $method = self::SETPRINTRANGE_OVERWRITE)
|
public function setPrintArea($value, $index = 0, $method = self::SETPRINTRANGE_OVERWRITE)
|
||||||
{
|
{
|
||||||
|
@ -732,7 +732,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function addPrintArea($value, $index = -1)
|
public function addPrintArea($value, $index = -1)
|
||||||
{
|
{
|
||||||
|
@ -762,7 +762,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPrintAreaByColumnAndRow($column1, $row1, $column2, $row2, $index = 0, $method = self::SETPRINTRANGE_OVERWRITE)
|
public function setPrintAreaByColumnAndRow($column1, $row1, $column2, $row2, $index = 0, $method = self::SETPRINTRANGE_OVERWRITE)
|
||||||
{
|
{
|
||||||
|
@ -789,7 +789,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function addPrintAreaByColumnAndRow($column1, $row1, $column2, $row2, $index = -1)
|
public function addPrintAreaByColumnAndRow($column1, $row1, $column2, $row2, $index = -1)
|
||||||
{
|
{
|
||||||
|
@ -815,7 +815,7 @@ class PageSetup
|
||||||
*
|
*
|
||||||
* @param int $value
|
* @param int $value
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFirstPageNumber($value)
|
public function setFirstPageNumber($value)
|
||||||
{
|
{
|
||||||
|
@ -827,7 +827,7 @@ class PageSetup
|
||||||
/**
|
/**
|
||||||
* Reset first page number.
|
* Reset first page number.
|
||||||
*
|
*
|
||||||
* @return PageSetup
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetFirstPageNumber()
|
public function resetFirstPageNumber()
|
||||||
{
|
{
|
||||||
|
|
|
@ -172,7 +172,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSheet($pValue)
|
public function setSheet($pValue)
|
||||||
{
|
{
|
||||||
|
@ -196,7 +196,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setObjects($pValue)
|
public function setObjects($pValue)
|
||||||
{
|
{
|
||||||
|
@ -220,7 +220,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setScenarios($pValue)
|
public function setScenarios($pValue)
|
||||||
{
|
{
|
||||||
|
@ -244,7 +244,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFormatCells($pValue)
|
public function setFormatCells($pValue)
|
||||||
{
|
{
|
||||||
|
@ -268,7 +268,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFormatColumns($pValue)
|
public function setFormatColumns($pValue)
|
||||||
{
|
{
|
||||||
|
@ -292,7 +292,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFormatRows($pValue)
|
public function setFormatRows($pValue)
|
||||||
{
|
{
|
||||||
|
@ -316,7 +316,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setInsertColumns($pValue)
|
public function setInsertColumns($pValue)
|
||||||
{
|
{
|
||||||
|
@ -340,7 +340,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setInsertRows($pValue)
|
public function setInsertRows($pValue)
|
||||||
{
|
{
|
||||||
|
@ -364,7 +364,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setInsertHyperlinks($pValue)
|
public function setInsertHyperlinks($pValue)
|
||||||
{
|
{
|
||||||
|
@ -388,7 +388,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDeleteColumns($pValue)
|
public function setDeleteColumns($pValue)
|
||||||
{
|
{
|
||||||
|
@ -412,7 +412,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDeleteRows($pValue)
|
public function setDeleteRows($pValue)
|
||||||
{
|
{
|
||||||
|
@ -436,7 +436,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSelectLockedCells($pValue)
|
public function setSelectLockedCells($pValue)
|
||||||
{
|
{
|
||||||
|
@ -460,7 +460,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSort($pValue)
|
public function setSort($pValue)
|
||||||
{
|
{
|
||||||
|
@ -484,7 +484,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAutoFilter($pValue)
|
public function setAutoFilter($pValue)
|
||||||
{
|
{
|
||||||
|
@ -508,7 +508,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPivotTables($pValue)
|
public function setPivotTables($pValue)
|
||||||
{
|
{
|
||||||
|
@ -532,7 +532,7 @@ class Protection
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSelectUnlockedCells($pValue)
|
public function setSelectUnlockedCells($pValue)
|
||||||
{
|
{
|
||||||
|
@ -557,7 +557,7 @@ class Protection
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
* @param bool $pAlreadyHashed If the password has already been hashed, set this to true
|
* @param bool $pAlreadyHashed If the password has already been hashed, set this to true
|
||||||
*
|
*
|
||||||
* @return Protection
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPassword($pValue, $pAlreadyHashed = false)
|
public function setPassword($pValue, $pAlreadyHashed = false)
|
||||||
{
|
{
|
||||||
|
|
|
@ -59,7 +59,7 @@ class RowCellIterator extends CellIterator
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return RowCellIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetStart($startColumn = 'A')
|
public function resetStart($startColumn = 'A')
|
||||||
{
|
{
|
||||||
|
@ -77,7 +77,7 @@ class RowCellIterator extends CellIterator
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return RowCellIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetEnd($endColumn = null)
|
public function resetEnd($endColumn = null)
|
||||||
{
|
{
|
||||||
|
@ -95,7 +95,7 @@ class RowCellIterator extends CellIterator
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return RowCellIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function seek($column = 'A')
|
public function seek($column = 'A')
|
||||||
{
|
{
|
||||||
|
|
|
@ -56,7 +56,7 @@ class RowDimension extends Dimension
|
||||||
*
|
*
|
||||||
* @param int $pValue
|
* @param int $pValue
|
||||||
*
|
*
|
||||||
* @return RowDimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRowIndex($pValue)
|
public function setRowIndex($pValue)
|
||||||
{
|
{
|
||||||
|
@ -80,7 +80,7 @@ class RowDimension extends Dimension
|
||||||
*
|
*
|
||||||
* @param float $pValue
|
* @param float $pValue
|
||||||
*
|
*
|
||||||
* @return RowDimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRowHeight($pValue)
|
public function setRowHeight($pValue)
|
||||||
{
|
{
|
||||||
|
@ -104,7 +104,7 @@ class RowDimension extends Dimension
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return RowDimension
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setZeroHeight($pValue)
|
public function setZeroHeight($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -64,7 +64,7 @@ class RowIterator implements \Iterator
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return RowIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetStart($startRow = 1)
|
public function resetStart($startRow = 1)
|
||||||
{
|
{
|
||||||
|
@ -86,7 +86,7 @@ class RowIterator implements \Iterator
|
||||||
*
|
*
|
||||||
* @param int $endRow The row number at which to stop iterating
|
* @param int $endRow The row number at which to stop iterating
|
||||||
*
|
*
|
||||||
* @return RowIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetEnd($endRow = null)
|
public function resetEnd($endRow = null)
|
||||||
{
|
{
|
||||||
|
@ -102,7 +102,7 @@ class RowIterator implements \Iterator
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return RowIterator
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function seek($row = 1)
|
public function seek($row = 1)
|
||||||
{
|
{
|
||||||
|
|
|
@ -79,7 +79,7 @@ class SheetView
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return SheetView
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setZoomScale($pValue)
|
public function setZoomScale($pValue)
|
||||||
{
|
{
|
||||||
|
@ -112,7 +112,7 @@ class SheetView
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return SheetView
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setZoomScaleNormal($pValue)
|
public function setZoomScaleNormal($pValue)
|
||||||
{
|
{
|
||||||
|
@ -165,7 +165,7 @@ class SheetView
|
||||||
*
|
*
|
||||||
* @throws PhpSpreadsheetException
|
* @throws PhpSpreadsheetException
|
||||||
*
|
*
|
||||||
* @return SheetView
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setView($pValue)
|
public function setView($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -647,7 +647,7 @@ class Worksheet implements IComparable
|
||||||
/**
|
/**
|
||||||
* Refresh column dimensions.
|
* Refresh column dimensions.
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function refreshColumnDimensions()
|
public function refreshColumnDimensions()
|
||||||
{
|
{
|
||||||
|
@ -666,7 +666,7 @@ class Worksheet implements IComparable
|
||||||
/**
|
/**
|
||||||
* Refresh row dimensions.
|
* Refresh row dimensions.
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function refreshRowDimensions()
|
public function refreshRowDimensions()
|
||||||
{
|
{
|
||||||
|
@ -707,7 +707,7 @@ class Worksheet implements IComparable
|
||||||
/**
|
/**
|
||||||
* Calculate widths for auto-size columns.
|
* Calculate widths for auto-size columns.
|
||||||
*
|
*
|
||||||
* @return Worksheet;
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function calculateColumnWidths()
|
public function calculateColumnWidths()
|
||||||
{
|
{
|
||||||
|
@ -797,7 +797,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param Spreadsheet $parent
|
* @param Spreadsheet $parent
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function rebindParent(Spreadsheet $parent)
|
public function rebindParent(Spreadsheet $parent)
|
||||||
{
|
{
|
||||||
|
@ -838,7 +838,7 @@ class Worksheet implements IComparable
|
||||||
* @param bool $validate False to skip validation of new title. WARNING: This should only be set
|
* @param bool $validate False to skip validation of new title. WARNING: This should only be set
|
||||||
* at parse time (by Readers), where titles can be assumed to be valid.
|
* at parse time (by Readers), where titles can be assumed to be valid.
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setTitle($pValue, $updateFormulaCellReferences = true, $validate = true)
|
public function setTitle($pValue, $updateFormulaCellReferences = true, $validate = true)
|
||||||
{
|
{
|
||||||
|
@ -913,7 +913,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $value Sheet state (visible, hidden, veryHidden)
|
* @param string $value Sheet state (visible, hidden, veryHidden)
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSheetState($value)
|
public function setSheetState($value)
|
||||||
{
|
{
|
||||||
|
@ -937,7 +937,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param PageSetup $pValue
|
* @param PageSetup $pValue
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPageSetup(PageSetup $pValue)
|
public function setPageSetup(PageSetup $pValue)
|
||||||
{
|
{
|
||||||
|
@ -961,7 +961,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param PageMargins $pValue
|
* @param PageMargins $pValue
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPageMargins(PageMargins $pValue)
|
public function setPageMargins(PageMargins $pValue)
|
||||||
{
|
{
|
||||||
|
@ -985,7 +985,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param HeaderFooter $pValue
|
* @param HeaderFooter $pValue
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setHeaderFooter(HeaderFooter $pValue)
|
public function setHeaderFooter(HeaderFooter $pValue)
|
||||||
{
|
{
|
||||||
|
@ -1009,7 +1009,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param SheetView $pValue
|
* @param SheetView $pValue
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSheetView(SheetView $pValue)
|
public function setSheetView(SheetView $pValue)
|
||||||
{
|
{
|
||||||
|
@ -1033,7 +1033,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param Protection $pValue
|
* @param Protection $pValue
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setProtection(Protection $pValue)
|
public function setProtection(Protection $pValue)
|
||||||
{
|
{
|
||||||
|
@ -1119,7 +1119,7 @@ class Worksheet implements IComparable
|
||||||
* @param string $pCoordinate Coordinate of the cell, eg: 'A1'
|
* @param string $pCoordinate Coordinate of the cell, eg: 'A1'
|
||||||
* @param mixed $pValue Value of the cell
|
* @param mixed $pValue Value of the cell
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCellValue($pCoordinate, $pValue)
|
public function setCellValue($pCoordinate, $pValue)
|
||||||
{
|
{
|
||||||
|
@ -1135,7 +1135,7 @@ class Worksheet implements IComparable
|
||||||
* @param int $row Numeric row coordinate of the cell
|
* @param int $row Numeric row coordinate of the cell
|
||||||
* @param mixed $value Value of the cell
|
* @param mixed $value Value of the cell
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCellValueByColumnAndRow($columnIndex, $row, $value)
|
public function setCellValueByColumnAndRow($columnIndex, $row, $value)
|
||||||
{
|
{
|
||||||
|
@ -1151,7 +1151,7 @@ class Worksheet implements IComparable
|
||||||
* @param mixed $pValue Value of the cell
|
* @param mixed $pValue Value of the cell
|
||||||
* @param string $pDataType Explicit data type, see DataType::TYPE_*
|
* @param string $pDataType Explicit data type, see DataType::TYPE_*
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCellValueExplicit($pCoordinate, $pValue, $pDataType)
|
public function setCellValueExplicit($pCoordinate, $pValue, $pDataType)
|
||||||
{
|
{
|
||||||
|
@ -1169,7 +1169,7 @@ class Worksheet implements IComparable
|
||||||
* @param mixed $value Value of the cell
|
* @param mixed $value Value of the cell
|
||||||
* @param string $dataType Explicit data type, see DataType::TYPE_*
|
* @param string $dataType Explicit data type, see DataType::TYPE_*
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCellValueExplicitByColumnAndRow($columnIndex, $row, $value, $dataType)
|
public function setCellValueExplicitByColumnAndRow($columnIndex, $row, $value, $dataType)
|
||||||
{
|
{
|
||||||
|
@ -1480,7 +1480,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $pCoordinate eg: 'A1'
|
* @param string $pCoordinate eg: 'A1'
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function removeConditionalStyles($pCoordinate)
|
public function removeConditionalStyles($pCoordinate)
|
||||||
{
|
{
|
||||||
|
@ -1505,7 +1505,7 @@ class Worksheet implements IComparable
|
||||||
* @param string $pCoordinate eg: 'A1'
|
* @param string $pCoordinate eg: 'A1'
|
||||||
* @param $pValue Conditional[]
|
* @param $pValue Conditional[]
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setConditionalStyles($pCoordinate, $pValue)
|
public function setConditionalStyles($pCoordinate, $pValue)
|
||||||
{
|
{
|
||||||
|
@ -1545,7 +1545,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function duplicateStyle(Style $pCellStyle, $pRange)
|
public function duplicateStyle(Style $pCellStyle, $pRange)
|
||||||
{
|
{
|
||||||
|
@ -1590,7 +1590,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function duplicateConditionalStyle(array $pCellStyle, $pRange = '')
|
public function duplicateConditionalStyle(array $pCellStyle, $pRange = '')
|
||||||
{
|
{
|
||||||
|
@ -1628,7 +1628,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setBreak($pCoordinate, $pBreak)
|
public function setBreak($pCoordinate, $pBreak)
|
||||||
{
|
{
|
||||||
|
@ -1657,7 +1657,7 @@ class Worksheet implements IComparable
|
||||||
* @param int $row Numeric row coordinate of the cell
|
* @param int $row Numeric row coordinate of the cell
|
||||||
* @param int $break Break type (type of Worksheet::BREAK_*)
|
* @param int $break Break type (type of Worksheet::BREAK_*)
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setBreakByColumnAndRow($columnIndex, $row, $break)
|
public function setBreakByColumnAndRow($columnIndex, $row, $break)
|
||||||
{
|
{
|
||||||
|
@ -1681,7 +1681,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function mergeCells($pRange)
|
public function mergeCells($pRange)
|
||||||
{
|
{
|
||||||
|
@ -1726,7 +1726,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function mergeCellsByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2)
|
public function mergeCellsByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2)
|
||||||
{
|
{
|
||||||
|
@ -1742,7 +1742,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function unmergeCells($pRange)
|
public function unmergeCells($pRange)
|
||||||
{
|
{
|
||||||
|
@ -1772,7 +1772,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function unmergeCellsByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2)
|
public function unmergeCellsByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2)
|
||||||
{
|
{
|
||||||
|
@ -1797,7 +1797,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param array $pValue
|
* @param array $pValue
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setMergeCells(array $pValue)
|
public function setMergeCells(array $pValue)
|
||||||
{
|
{
|
||||||
|
@ -1813,7 +1813,7 @@ class Worksheet implements IComparable
|
||||||
* @param string $pPassword Password to unlock the protection
|
* @param string $pPassword Password to unlock the protection
|
||||||
* @param bool $pAlreadyHashed If the password has already been hashed, set this to true
|
* @param bool $pAlreadyHashed If the password has already been hashed, set this to true
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function protectCells($pRange, $pPassword, $pAlreadyHashed = false)
|
public function protectCells($pRange, $pPassword, $pAlreadyHashed = false)
|
||||||
{
|
{
|
||||||
|
@ -1838,7 +1838,7 @@ class Worksheet implements IComparable
|
||||||
* @param string $password Password to unlock the protection
|
* @param string $password Password to unlock the protection
|
||||||
* @param bool $alreadyHashed If the password has already been hashed, set this to true
|
* @param bool $alreadyHashed If the password has already been hashed, set this to true
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function protectCellsByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2, $password, $alreadyHashed = false)
|
public function protectCellsByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2, $password, $alreadyHashed = false)
|
||||||
{
|
{
|
||||||
|
@ -1854,7 +1854,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function unprotectCells($pRange)
|
public function unprotectCells($pRange)
|
||||||
{
|
{
|
||||||
|
@ -1880,7 +1880,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function unprotectCellsByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2)
|
public function unprotectCellsByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2)
|
||||||
{
|
{
|
||||||
|
@ -1917,7 +1917,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAutoFilter($pValue)
|
public function setAutoFilter($pValue)
|
||||||
{
|
{
|
||||||
|
@ -1940,7 +1940,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setAutoFilterByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2)
|
public function setAutoFilterByColumnAndRow($columnIndex1, $row1, $columnIndex2, $row2)
|
||||||
{
|
{
|
||||||
|
@ -1954,7 +1954,7 @@ class Worksheet implements IComparable
|
||||||
/**
|
/**
|
||||||
* Remove autofilter.
|
* Remove autofilter.
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function removeAutoFilter()
|
public function removeAutoFilter()
|
||||||
{
|
{
|
||||||
|
@ -1987,7 +1987,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function freezePane($cell, $topLeftCell = null)
|
public function freezePane($cell, $topLeftCell = null)
|
||||||
{
|
{
|
||||||
|
@ -2012,7 +2012,7 @@ class Worksheet implements IComparable
|
||||||
* @param int $columnIndex Numeric column coordinate of the cell
|
* @param int $columnIndex Numeric column coordinate of the cell
|
||||||
* @param int $row Numeric row coordinate of the cell
|
* @param int $row Numeric row coordinate of the cell
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function freezePaneByColumnAndRow($columnIndex, $row)
|
public function freezePaneByColumnAndRow($columnIndex, $row)
|
||||||
{
|
{
|
||||||
|
@ -2022,7 +2022,7 @@ class Worksheet implements IComparable
|
||||||
/**
|
/**
|
||||||
* Unfreeze Pane.
|
* Unfreeze Pane.
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function unfreezePane()
|
public function unfreezePane()
|
||||||
{
|
{
|
||||||
|
@ -2047,7 +2047,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function insertNewRowBefore($pBefore, $pNumRows = 1)
|
public function insertNewRowBefore($pBefore, $pNumRows = 1)
|
||||||
{
|
{
|
||||||
|
@ -2069,7 +2069,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function insertNewColumnBefore($pBefore, $pNumCols = 1)
|
public function insertNewColumnBefore($pBefore, $pNumCols = 1)
|
||||||
{
|
{
|
||||||
|
@ -2091,7 +2091,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function insertNewColumnBeforeByIndex($beforeColumnIndex, $pNumCols = 1)
|
public function insertNewColumnBeforeByIndex($beforeColumnIndex, $pNumCols = 1)
|
||||||
{
|
{
|
||||||
|
@ -2110,25 +2110,30 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function removeRow($pRow, $pNumRows = 1)
|
public function removeRow($pRow, $pNumRows = 1)
|
||||||
{
|
{
|
||||||
if ($pRow >= 1) {
|
if ($pRow < 1) {
|
||||||
for ($r = 0; $r < $pNumRows; ++$r) {
|
throw new Exception('Rows to be deleted should at least start from row 1.');
|
||||||
$this->getCellCollection()->removeRow($pRow + $r);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$highestRow = $this->getHighestDataRow();
|
$highestRow = $this->getHighestDataRow();
|
||||||
|
$removedRowsCounter = 0;
|
||||||
|
|
||||||
|
for ($r = 0; $r < $pNumRows; ++$r) {
|
||||||
|
if ($pRow + $r <= $highestRow) {
|
||||||
|
$this->getCellCollection()->removeRow($pRow + $r);
|
||||||
|
++$removedRowsCounter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$objReferenceHelper = ReferenceHelper::getInstance();
|
$objReferenceHelper = ReferenceHelper::getInstance();
|
||||||
$objReferenceHelper->insertNewBefore('A' . ($pRow + $pNumRows), 0, -$pNumRows, $this);
|
$objReferenceHelper->insertNewBefore('A' . ($pRow + $pNumRows), 0, -$pNumRows, $this);
|
||||||
for ($r = 0; $r < $pNumRows; ++$r) {
|
for ($r = 0; $r < $removedRowsCounter; ++$r) {
|
||||||
$this->getCellCollection()->removeRow($highestRow);
|
$this->getCellCollection()->removeRow($highestRow);
|
||||||
--$highestRow;
|
--$highestRow;
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
throw new Exception('Rows to be deleted should at least start from row 1.');
|
|
||||||
}
|
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
@ -2141,7 +2146,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function removeColumn($pColumn, $pNumCols = 1)
|
public function removeColumn($pColumn, $pNumCols = 1)
|
||||||
{
|
{
|
||||||
|
@ -2181,7 +2186,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function removeColumnByIndex($columnIndex, $numColumns = 1)
|
public function removeColumnByIndex($columnIndex, $numColumns = 1)
|
||||||
{
|
{
|
||||||
|
@ -2207,7 +2212,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $pValue Show gridlines (true/false)
|
* @param bool $pValue Show gridlines (true/false)
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowGridlines($pValue)
|
public function setShowGridlines($pValue)
|
||||||
{
|
{
|
||||||
|
@ -2231,7 +2236,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $pValue Print gridlines (true/false)
|
* @param bool $pValue Print gridlines (true/false)
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setPrintGridlines($pValue)
|
public function setPrintGridlines($pValue)
|
||||||
{
|
{
|
||||||
|
@ -2255,7 +2260,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $pValue Show row and column headers (true/false)
|
* @param bool $pValue Show row and column headers (true/false)
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowRowColHeaders($pValue)
|
public function setShowRowColHeaders($pValue)
|
||||||
{
|
{
|
||||||
|
@ -2279,7 +2284,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $pValue Show summary below (true/false)
|
* @param bool $pValue Show summary below (true/false)
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowSummaryBelow($pValue)
|
public function setShowSummaryBelow($pValue)
|
||||||
{
|
{
|
||||||
|
@ -2303,7 +2308,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $pValue Show summary right (true/false)
|
* @param bool $pValue Show summary right (true/false)
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setShowSummaryRight($pValue)
|
public function setShowSummaryRight($pValue)
|
||||||
{
|
{
|
||||||
|
@ -2327,7 +2332,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param Comment[] $pValue
|
* @param Comment[] $pValue
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setComments(array $pValue)
|
public function setComments(array $pValue)
|
||||||
{
|
{
|
||||||
|
@ -2408,7 +2413,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $pCoordinate Cell (i.e. A1)
|
* @param string $pCoordinate Cell (i.e. A1)
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSelectedCell($pCoordinate)
|
public function setSelectedCell($pCoordinate)
|
||||||
{
|
{
|
||||||
|
@ -2420,7 +2425,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param string $pCoordinate Cell range, examples: 'A1', 'B2:G5', 'A:C', '3:6'
|
* @param string $pCoordinate Cell range, examples: 'A1', 'B2:G5', 'A:C', '3:6'
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSelectedCells($pCoordinate)
|
public function setSelectedCells($pCoordinate)
|
||||||
{
|
{
|
||||||
|
@ -2458,7 +2463,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSelectedCellByColumnAndRow($columnIndex, $row)
|
public function setSelectedCellByColumnAndRow($columnIndex, $row)
|
||||||
{
|
{
|
||||||
|
@ -2480,7 +2485,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @param bool $value Right-to-left true/false
|
* @param bool $value Right-to-left true/false
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setRightToLeft($value)
|
public function setRightToLeft($value)
|
||||||
{
|
{
|
||||||
|
@ -2499,7 +2504,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function fromArray(array $source, $nullValue = null, $startCell = 'A1', $strictNullComparison = false)
|
public function fromArray(array $source, $nullValue = null, $startCell = 'A1', $strictNullComparison = false)
|
||||||
{
|
{
|
||||||
|
@ -2684,7 +2689,7 @@ class Worksheet implements IComparable
|
||||||
/**
|
/**
|
||||||
* Run PhpSpreadsheet garbage collector.
|
* Run PhpSpreadsheet garbage collector.
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function garbageCollect()
|
public function garbageCollect()
|
||||||
{
|
{
|
||||||
|
@ -2784,7 +2789,7 @@ class Worksheet implements IComparable
|
||||||
* @param string $pCellCoordinate Cell coordinate to insert hyperlink, eg: 'A1'
|
* @param string $pCellCoordinate Cell coordinate to insert hyperlink, eg: 'A1'
|
||||||
* @param null|Hyperlink $pHyperlink
|
* @param null|Hyperlink $pHyperlink
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setHyperlink($pCellCoordinate, Hyperlink $pHyperlink = null)
|
public function setHyperlink($pCellCoordinate, Hyperlink $pHyperlink = null)
|
||||||
{
|
{
|
||||||
|
@ -2845,7 +2850,7 @@ class Worksheet implements IComparable
|
||||||
* @param string $pCellCoordinate Cell coordinate to insert data validation, eg: 'A1'
|
* @param string $pCellCoordinate Cell coordinate to insert data validation, eg: 'A1'
|
||||||
* @param null|DataValidation $pDataValidation
|
* @param null|DataValidation $pDataValidation
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDataValidation($pCellCoordinate, DataValidation $pDataValidation = null)
|
public function setDataValidation($pCellCoordinate, DataValidation $pDataValidation = null)
|
||||||
{
|
{
|
||||||
|
@ -2933,7 +2938,7 @@ class Worksheet implements IComparable
|
||||||
/**
|
/**
|
||||||
* Reset tab color.
|
* Reset tab color.
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function resetTabColor()
|
public function resetTabColor()
|
||||||
{
|
{
|
||||||
|
@ -2956,7 +2961,7 @@ class Worksheet implements IComparable
|
||||||
/**
|
/**
|
||||||
* Copy worksheet (!= clone!).
|
* Copy worksheet (!= clone!).
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return static
|
||||||
*/
|
*/
|
||||||
public function copy()
|
public function copy()
|
||||||
{
|
{
|
||||||
|
@ -3007,7 +3012,7 @@ class Worksheet implements IComparable
|
||||||
*
|
*
|
||||||
* @throws Exception
|
* @throws Exception
|
||||||
*
|
*
|
||||||
* @return Worksheet
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setCodeName($pValue, $validate = true)
|
public function setCodeName($pValue, $validate = true)
|
||||||
{
|
{
|
||||||
|
|
|
@ -147,7 +147,7 @@ class Csv extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param string $pValue Delimiter, defaults to ','
|
* @param string $pValue Delimiter, defaults to ','
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setDelimiter($pValue)
|
public function setDelimiter($pValue)
|
||||||
{
|
{
|
||||||
|
@ -171,7 +171,7 @@ class Csv extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param string $pValue Enclosure, defaults to "
|
* @param string $pValue Enclosure, defaults to "
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setEnclosure($pValue)
|
public function setEnclosure($pValue)
|
||||||
{
|
{
|
||||||
|
@ -198,7 +198,7 @@ class Csv extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param string $pValue Line ending, defaults to OS line ending (PHP_EOL)
|
* @param string $pValue Line ending, defaults to OS line ending (PHP_EOL)
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setLineEnding($pValue)
|
public function setLineEnding($pValue)
|
||||||
{
|
{
|
||||||
|
@ -222,7 +222,7 @@ class Csv extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param bool $pValue Use UTF-8 byte-order mark? Defaults to false
|
* @param bool $pValue Use UTF-8 byte-order mark? Defaults to false
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setUseBOM($pValue)
|
public function setUseBOM($pValue)
|
||||||
{
|
{
|
||||||
|
@ -246,7 +246,7 @@ class Csv extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param bool $pValue Use separator line? Defaults to false
|
* @param bool $pValue Use separator line? Defaults to false
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setIncludeSeparatorLine($pValue)
|
public function setIncludeSeparatorLine($pValue)
|
||||||
{
|
{
|
||||||
|
@ -271,7 +271,7 @@ class Csv extends BaseWriter
|
||||||
* @param bool $pValue Set the file to be written as a fully Excel compatible csv file
|
* @param bool $pValue Set the file to be written as a fully Excel compatible csv file
|
||||||
* Note that this overrides other settings such as useBOM, enclosure and delimiter
|
* Note that this overrides other settings such as useBOM, enclosure and delimiter
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setExcelCompatibility($pValue)
|
public function setExcelCompatibility($pValue)
|
||||||
{
|
{
|
||||||
|
@ -295,7 +295,7 @@ class Csv extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param int $pValue Sheet index
|
* @param int $pValue Sheet index
|
||||||
*
|
*
|
||||||
* @return CSV
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSheetIndex($pValue)
|
public function setSheetIndex($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -297,7 +297,7 @@ class Html extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param int $pValue Sheet index
|
* @param int $pValue Sheet index
|
||||||
*
|
*
|
||||||
* @return HTML
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSheetIndex($pValue)
|
public function setSheetIndex($pValue)
|
||||||
{
|
{
|
||||||
|
@ -321,7 +321,7 @@ class Html extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param bool $pValue Flag indicating whether the sheet navigation block should be generated or not
|
* @param bool $pValue Flag indicating whether the sheet navigation block should be generated or not
|
||||||
*
|
*
|
||||||
* @return HTML
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setGenerateSheetNavigationBlock($pValue)
|
public function setGenerateSheetNavigationBlock($pValue)
|
||||||
{
|
{
|
||||||
|
@ -332,6 +332,8 @@ class Html extends BaseWriter
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Write all sheets (resets sheetIndex to NULL).
|
* Write all sheets (resets sheetIndex to NULL).
|
||||||
|
*
|
||||||
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function writeAllSheets()
|
public function writeAllSheets()
|
||||||
{
|
{
|
||||||
|
@ -1438,7 +1440,7 @@ class Html extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param string $pValue
|
* @param string $pValue
|
||||||
*
|
*
|
||||||
* @return HTML
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setImagesRoot($pValue)
|
public function setImagesRoot($pValue)
|
||||||
{
|
{
|
||||||
|
@ -1462,7 +1464,7 @@ class Html extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return HTML
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setEmbedImages($pValue)
|
public function setEmbedImages($pValue)
|
||||||
{
|
{
|
||||||
|
@ -1486,7 +1488,7 @@ class Html extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return HTML
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setUseInlineCss($pValue)
|
public function setUseInlineCss($pValue)
|
||||||
{
|
{
|
||||||
|
@ -1510,7 +1512,7 @@ class Html extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param bool $pValue
|
* @param bool $pValue
|
||||||
*
|
*
|
||||||
* @return HTML
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setUseEmbeddedCSS($pValue)
|
public function setUseEmbeddedCSS($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -167,7 +167,7 @@ class Ods extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param Spreadsheet $spreadsheet PhpSpreadsheet object
|
* @param Spreadsheet $spreadsheet PhpSpreadsheet object
|
||||||
*
|
*
|
||||||
* @return self
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSpreadsheet(Spreadsheet $spreadsheet)
|
public function setSpreadsheet(Spreadsheet $spreadsheet)
|
||||||
{
|
{
|
||||||
|
|
|
@ -150,7 +150,7 @@ abstract class Pdf extends Html
|
||||||
*
|
*
|
||||||
* @param string $fontName
|
* @param string $fontName
|
||||||
*
|
*
|
||||||
* @return Pdf
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setFont($fontName)
|
public function setFont($fontName)
|
||||||
{
|
{
|
||||||
|
|
|
@ -281,6 +281,10 @@ class Worksheet extends BIFFwriter
|
||||||
{
|
{
|
||||||
$phpSheet = $this->phpSheet;
|
$phpSheet = $this->phpSheet;
|
||||||
|
|
||||||
|
// Storing selected cells and active sheet because it changes while parsing cells with formulas.
|
||||||
|
$selectedCells = $this->phpSheet->getSelectedCells();
|
||||||
|
$activeSheetIndex = $this->phpSheet->getParent()->getActiveSheetIndex();
|
||||||
|
|
||||||
// Write BOF record
|
// Write BOF record
|
||||||
$this->storeBof(0x0010);
|
$this->storeBof(0x0010);
|
||||||
|
|
||||||
|
@ -481,6 +485,9 @@ class Worksheet extends BIFFwriter
|
||||||
// Append
|
// Append
|
||||||
$this->writeMsoDrawing();
|
$this->writeMsoDrawing();
|
||||||
|
|
||||||
|
// Restoring active sheet.
|
||||||
|
$this->phpSheet->getParent()->setActiveSheetIndex($activeSheetIndex);
|
||||||
|
|
||||||
// Write WINDOW2 record
|
// Write WINDOW2 record
|
||||||
$this->writeWindow2();
|
$this->writeWindow2();
|
||||||
|
|
||||||
|
@ -493,6 +500,9 @@ class Worksheet extends BIFFwriter
|
||||||
$this->writePanes();
|
$this->writePanes();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Restoring selected cells.
|
||||||
|
$this->phpSheet->setSelectedCells($selectedCells);
|
||||||
|
|
||||||
// Write SELECTION record
|
// Write SELECTION record
|
||||||
$this->writeSelection();
|
$this->writeSelection();
|
||||||
|
|
||||||
|
@ -1250,7 +1260,6 @@ class Worksheet extends BIFFwriter
|
||||||
$fFrozenNoSplit = 0; // 0 - bit
|
$fFrozenNoSplit = 0; // 0 - bit
|
||||||
// no support in PhpSpreadsheet for selected sheet, therefore sheet is only selected if it is the active sheet
|
// no support in PhpSpreadsheet for selected sheet, therefore sheet is only selected if it is the active sheet
|
||||||
$fSelected = ($this->phpSheet === $this->phpSheet->getParent()->getActiveSheet()) ? 1 : 0;
|
$fSelected = ($this->phpSheet === $this->phpSheet->getParent()->getActiveSheet()) ? 1 : 0;
|
||||||
$fPaged = 1; // 2
|
|
||||||
$fPageBreakPreview = $this->phpSheet->getSheetView()->getView() === SheetView::SHEETVIEW_PAGE_BREAK_PREVIEW;
|
$fPageBreakPreview = $this->phpSheet->getSheetView()->getView() === SheetView::SHEETVIEW_PAGE_BREAK_PREVIEW;
|
||||||
|
|
||||||
$grbit = $fDspFmla;
|
$grbit = $fDspFmla;
|
||||||
|
@ -1262,8 +1271,8 @@ class Worksheet extends BIFFwriter
|
||||||
$grbit |= $fArabic << 6;
|
$grbit |= $fArabic << 6;
|
||||||
$grbit |= $fDspGuts << 7;
|
$grbit |= $fDspGuts << 7;
|
||||||
$grbit |= $fFrozenNoSplit << 8;
|
$grbit |= $fFrozenNoSplit << 8;
|
||||||
$grbit |= $fSelected << 9;
|
$grbit |= $fSelected << 9; // Selected sheets.
|
||||||
$grbit |= $fPaged << 10;
|
$grbit |= $fSelected << 10; // Active sheet.
|
||||||
$grbit |= $fPageBreakPreview << 11;
|
$grbit |= $fPageBreakPreview << 11;
|
||||||
|
|
||||||
$header = pack('vv', $record, $length);
|
$header = pack('vv', $record, $length);
|
||||||
|
|
|
@ -443,7 +443,7 @@ class Xlsx extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param Spreadsheet $spreadsheet PhpSpreadsheet object
|
* @param Spreadsheet $spreadsheet PhpSpreadsheet object
|
||||||
*
|
*
|
||||||
* @return Xlsx
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setSpreadsheet(Spreadsheet $spreadsheet)
|
public function setSpreadsheet(Spreadsheet $spreadsheet)
|
||||||
{
|
{
|
||||||
|
@ -547,7 +547,7 @@ class Xlsx extends BaseWriter
|
||||||
*
|
*
|
||||||
* @param bool $pValue Office2003 compatibility?
|
* @param bool $pValue Office2003 compatibility?
|
||||||
*
|
*
|
||||||
* @return Xlsx
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setOffice2003Compatibility($pValue)
|
public function setOffice2003Compatibility($pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -262,8 +262,6 @@ class Worksheet extends WriterPart
|
||||||
--$ySplit;
|
--$ySplit;
|
||||||
|
|
||||||
$topLeftCell = $pSheet->getTopLeftCell();
|
$topLeftCell = $pSheet->getTopLeftCell();
|
||||||
$activeCell = $topLeftCell;
|
|
||||||
$sqref = $topLeftCell;
|
|
||||||
|
|
||||||
// pane
|
// pane
|
||||||
$pane = 'topRight';
|
$pane = 'topRight';
|
||||||
|
|
|
@ -9,12 +9,12 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class CalculationTest extends TestCase
|
class CalculationTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function tearDown()
|
protected function tearDown(): void
|
||||||
{
|
{
|
||||||
$calculation = Calculation::getInstance();
|
$calculation = Calculation::getInstance();
|
||||||
$calculation->setLocale('en_us');
|
$calculation->setLocale('en_us');
|
||||||
|
|
|
@ -8,7 +8,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class FinancialTest extends TestCase
|
class FinancialTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
}
|
}
|
||||||
|
@ -21,7 +21,7 @@ class FinancialTest extends TestCase
|
||||||
public function testAMORDEGRC($expectedResult, ...$args)
|
public function testAMORDEGRC($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::AMORDEGRC(...$args);
|
$result = Financial::AMORDEGRC(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerAMORDEGRC()
|
public function providerAMORDEGRC()
|
||||||
|
@ -37,7 +37,7 @@ class FinancialTest extends TestCase
|
||||||
public function testAMORLINC($expectedResult, ...$args)
|
public function testAMORLINC($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::AMORLINC(...$args);
|
$result = Financial::AMORLINC(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerAMORLINC()
|
public function providerAMORLINC()
|
||||||
|
@ -53,7 +53,7 @@ class FinancialTest extends TestCase
|
||||||
public function testCOUPDAYBS($expectedResult, ...$args)
|
public function testCOUPDAYBS($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::COUPDAYBS(...$args);
|
$result = Financial::COUPDAYBS(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerCOUPDAYBS()
|
public function providerCOUPDAYBS()
|
||||||
|
@ -69,7 +69,7 @@ class FinancialTest extends TestCase
|
||||||
public function testCOUPDAYS($expectedResult, ...$args)
|
public function testCOUPDAYS($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::COUPDAYS(...$args);
|
$result = Financial::COUPDAYS(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerCOUPDAYS()
|
public function providerCOUPDAYS()
|
||||||
|
@ -85,7 +85,7 @@ class FinancialTest extends TestCase
|
||||||
public function testCOUPDAYSNC($expectedResult, ...$args)
|
public function testCOUPDAYSNC($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::COUPDAYSNC(...$args);
|
$result = Financial::COUPDAYSNC(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerCOUPDAYSNC()
|
public function providerCOUPDAYSNC()
|
||||||
|
@ -101,7 +101,7 @@ class FinancialTest extends TestCase
|
||||||
public function testCOUPNCD($expectedResult, ...$args)
|
public function testCOUPNCD($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::COUPNCD(...$args);
|
$result = Financial::COUPNCD(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerCOUPNCD()
|
public function providerCOUPNCD()
|
||||||
|
@ -117,7 +117,7 @@ class FinancialTest extends TestCase
|
||||||
public function testCOUPNUM($expectedResult, ...$args)
|
public function testCOUPNUM($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::COUPNUM(...$args);
|
$result = Financial::COUPNUM(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerCOUPNUM()
|
public function providerCOUPNUM()
|
||||||
|
@ -133,7 +133,7 @@ class FinancialTest extends TestCase
|
||||||
public function testCOUPPCD($expectedResult, ...$args)
|
public function testCOUPPCD($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::COUPPCD(...$args);
|
$result = Financial::COUPPCD(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerCOUPPCD()
|
public function providerCOUPPCD()
|
||||||
|
@ -149,7 +149,7 @@ class FinancialTest extends TestCase
|
||||||
public function testCUMIPMT($expectedResult, ...$args)
|
public function testCUMIPMT($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::CUMIPMT(...$args);
|
$result = Financial::CUMIPMT(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerCUMIPMT()
|
public function providerCUMIPMT()
|
||||||
|
@ -165,7 +165,7 @@ class FinancialTest extends TestCase
|
||||||
public function testCUMPRINC($expectedResult, ...$args)
|
public function testCUMPRINC($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::CUMPRINC(...$args);
|
$result = Financial::CUMPRINC(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerCUMPRINC()
|
public function providerCUMPRINC()
|
||||||
|
@ -181,7 +181,7 @@ class FinancialTest extends TestCase
|
||||||
public function testDB($expectedResult, ...$args)
|
public function testDB($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::DB(...$args);
|
$result = Financial::DB(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDB()
|
public function providerDB()
|
||||||
|
@ -197,7 +197,7 @@ class FinancialTest extends TestCase
|
||||||
public function testDDB($expectedResult, ...$args)
|
public function testDDB($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::DDB(...$args);
|
$result = Financial::DDB(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDDB()
|
public function providerDDB()
|
||||||
|
@ -213,7 +213,7 @@ class FinancialTest extends TestCase
|
||||||
public function testDISC($expectedResult, ...$args)
|
public function testDISC($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::DISC(...$args);
|
$result = Financial::DISC(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDISC()
|
public function providerDISC()
|
||||||
|
@ -229,7 +229,7 @@ class FinancialTest extends TestCase
|
||||||
public function testDOLLARDE($expectedResult, ...$args)
|
public function testDOLLARDE($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::DOLLARDE(...$args);
|
$result = Financial::DOLLARDE(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDOLLARDE()
|
public function providerDOLLARDE()
|
||||||
|
@ -245,7 +245,7 @@ class FinancialTest extends TestCase
|
||||||
public function testDOLLARFR($expectedResult, ...$args)
|
public function testDOLLARFR($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::DOLLARFR(...$args);
|
$result = Financial::DOLLARFR(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDOLLARFR()
|
public function providerDOLLARFR()
|
||||||
|
@ -261,7 +261,7 @@ class FinancialTest extends TestCase
|
||||||
public function testEFFECT($expectedResult, ...$args)
|
public function testEFFECT($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::EFFECT(...$args);
|
$result = Financial::EFFECT(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerEFFECT()
|
public function providerEFFECT()
|
||||||
|
@ -277,7 +277,7 @@ class FinancialTest extends TestCase
|
||||||
public function testFV($expectedResult, ...$args)
|
public function testFV($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::FV(...$args);
|
$result = Financial::FV(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerFV()
|
public function providerFV()
|
||||||
|
@ -293,7 +293,7 @@ class FinancialTest extends TestCase
|
||||||
public function testFVSCHEDULE($expectedResult, ...$args)
|
public function testFVSCHEDULE($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::FVSCHEDULE(...$args);
|
$result = Financial::FVSCHEDULE(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerFVSCHEDULE()
|
public function providerFVSCHEDULE()
|
||||||
|
@ -309,7 +309,7 @@ class FinancialTest extends TestCase
|
||||||
public function testINTRATE($expectedResult, ...$args)
|
public function testINTRATE($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::INTRATE(...$args);
|
$result = Financial::INTRATE(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerINTRATE()
|
public function providerINTRATE()
|
||||||
|
@ -325,7 +325,7 @@ class FinancialTest extends TestCase
|
||||||
public function testIPMT($expectedResult, ...$args)
|
public function testIPMT($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::IPMT(...$args);
|
$result = Financial::IPMT(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerIPMT()
|
public function providerIPMT()
|
||||||
|
@ -341,7 +341,7 @@ class FinancialTest extends TestCase
|
||||||
public function testIRR($expectedResult, ...$args)
|
public function testIRR($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::IRR(...$args);
|
$result = Financial::IRR(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerIRR()
|
public function providerIRR()
|
||||||
|
@ -357,7 +357,7 @@ class FinancialTest extends TestCase
|
||||||
public function testISPMT($expectedResult, ...$args)
|
public function testISPMT($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::ISPMT(...$args);
|
$result = Financial::ISPMT(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerISPMT()
|
public function providerISPMT()
|
||||||
|
@ -373,7 +373,7 @@ class FinancialTest extends TestCase
|
||||||
public function testMIRR($expectedResult, ...$args)
|
public function testMIRR($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::MIRR(...$args);
|
$result = Financial::MIRR(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerMIRR()
|
public function providerMIRR()
|
||||||
|
@ -389,7 +389,7 @@ class FinancialTest extends TestCase
|
||||||
public function testNOMINAL($expectedResult, ...$args)
|
public function testNOMINAL($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::NOMINAL(...$args);
|
$result = Financial::NOMINAL(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerNOMINAL()
|
public function providerNOMINAL()
|
||||||
|
@ -405,7 +405,7 @@ class FinancialTest extends TestCase
|
||||||
public function testNPER($expectedResult, ...$args)
|
public function testNPER($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::NPER(...$args);
|
$result = Financial::NPER(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerNPER()
|
public function providerNPER()
|
||||||
|
@ -421,7 +421,7 @@ class FinancialTest extends TestCase
|
||||||
public function testNPV($expectedResult, ...$args)
|
public function testNPV($expectedResult, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::NPV(...$args);
|
$result = Financial::NPV(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerNPV()
|
public function providerNPV()
|
||||||
|
@ -439,7 +439,7 @@ class FinancialTest extends TestCase
|
||||||
$this->markTestIncomplete('TODO: This test should be fixed');
|
$this->markTestIncomplete('TODO: This test should be fixed');
|
||||||
|
|
||||||
$result = Financial::PRICE(...$args);
|
$result = Financial::PRICE(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerPRICE()
|
public function providerPRICE()
|
||||||
|
@ -455,7 +455,7 @@ class FinancialTest extends TestCase
|
||||||
public function testPRICEDISC($expectedResult, array $args)
|
public function testPRICEDISC($expectedResult, array $args)
|
||||||
{
|
{
|
||||||
$result = Financial::PRICEDISC(...$args);
|
$result = Financial::PRICEDISC(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerPRICEDISC()
|
public function providerPRICEDISC()
|
||||||
|
@ -471,7 +471,7 @@ class FinancialTest extends TestCase
|
||||||
public function testPV($expectedResult, array $args)
|
public function testPV($expectedResult, array $args)
|
||||||
{
|
{
|
||||||
$result = Financial::PV(...$args);
|
$result = Financial::PV(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerPV()
|
public function providerPV()
|
||||||
|
@ -489,7 +489,7 @@ class FinancialTest extends TestCase
|
||||||
$this->markTestIncomplete('TODO: This test should be fixed');
|
$this->markTestIncomplete('TODO: This test should be fixed');
|
||||||
|
|
||||||
$result = Financial::RATE(...$args);
|
$result = Financial::RATE(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerRATE()
|
public function providerRATE()
|
||||||
|
@ -506,7 +506,7 @@ class FinancialTest extends TestCase
|
||||||
public function testXIRR($expectedResult, $message, ...$args)
|
public function testXIRR($expectedResult, $message, ...$args)
|
||||||
{
|
{
|
||||||
$result = Financial::XIRR(...$args);
|
$result = Financial::XIRR(...$args);
|
||||||
self::assertEquals($expectedResult, $result, $message, Financial::FINANCIAL_PRECISION);
|
self::assertEqualsWithDelta($expectedResult, $result, Financial::FINANCIAL_PRECISION, $message);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerXIRR()
|
public function providerXIRR()
|
||||||
|
@ -522,7 +522,7 @@ class FinancialTest extends TestCase
|
||||||
public function testPDURATION($expectedResult, array $args)
|
public function testPDURATION($expectedResult, array $args)
|
||||||
{
|
{
|
||||||
$result = Financial::PDURATION(...$args);
|
$result = Financial::PDURATION(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerPDURATION()
|
public function providerPDURATION()
|
||||||
|
@ -538,7 +538,7 @@ class FinancialTest extends TestCase
|
||||||
public function testRRI($expectedResult, array $args)
|
public function testRRI($expectedResult, array $args)
|
||||||
{
|
{
|
||||||
$result = Financial::RRI(...$args);
|
$result = Financial::RRI(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerRRI()
|
public function providerRRI()
|
||||||
|
@ -554,7 +554,7 @@ class FinancialTest extends TestCase
|
||||||
public function testSLN($expectedResult, array $args)
|
public function testSLN($expectedResult, array $args)
|
||||||
{
|
{
|
||||||
$result = Financial::SLN(...$args);
|
$result = Financial::SLN(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerSLN()
|
public function providerSLN()
|
||||||
|
@ -570,7 +570,7 @@ class FinancialTest extends TestCase
|
||||||
public function testSYD($expectedResult, array $args)
|
public function testSYD($expectedResult, array $args)
|
||||||
{
|
{
|
||||||
$result = Financial::SYD(...$args);
|
$result = Financial::SYD(...$args);
|
||||||
self::assertEquals($expectedResult, $result, '', 1E-8);
|
self::assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerSYD()
|
public function providerSYD()
|
||||||
|
|
|
@ -0,0 +1,46 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
namespace PhpOffice\PhpSpreadsheetTests\Calculation;
|
||||||
|
|
||||||
|
use PhpOffice\PhpSpreadsheet\Spreadsheet;
|
||||||
|
use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
|
class FormulaAsStringTest extends TestCase
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* @dataProvider providerFunctionsAsString
|
||||||
|
*
|
||||||
|
* @param mixed $expectedResult
|
||||||
|
* @param string $formula
|
||||||
|
*/
|
||||||
|
public function testFunctionsAsString($expectedResult, $formula)
|
||||||
|
{
|
||||||
|
$spreadsheet = new Spreadsheet();
|
||||||
|
$workSheet = $spreadsheet->getActiveSheet();
|
||||||
|
$workSheet->setCellValue('A1', 10);
|
||||||
|
$workSheet->setCellValue('A2', 20);
|
||||||
|
$workSheet->setCellValue('A3', 30);
|
||||||
|
$workSheet->setCellValue('A4', 40);
|
||||||
|
$spreadsheet->addNamedRange(new \PhpOffice\PhpSpreadsheet\NamedRange('namedCell', $workSheet, 'A4'));
|
||||||
|
$workSheet->setCellValue('B1', 'uPPER');
|
||||||
|
$workSheet->setCellValue('B2', '=TRUE()');
|
||||||
|
$workSheet->setCellValue('B3', '=FALSE()');
|
||||||
|
|
||||||
|
$ws2 = $spreadsheet->createSheet();
|
||||||
|
$ws2->setCellValue('A1', 100);
|
||||||
|
$ws2->setCellValue('A2', 200);
|
||||||
|
$ws2->setTitle('Sheet2');
|
||||||
|
$spreadsheet->addNamedRange(new \PhpOffice\PhpSpreadsheet\NamedRange('A2B', $ws2, 'A2'));
|
||||||
|
|
||||||
|
$spreadsheet->setActiveSheetIndex(0);
|
||||||
|
$cell2 = $workSheet->getCell('D1');
|
||||||
|
$cell2->setValue($formula);
|
||||||
|
$result = $cell2->getCalculatedValue();
|
||||||
|
self::assertEquals($expectedResult, $result);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function providerFunctionsAsString()
|
||||||
|
{
|
||||||
|
return require 'data/Calculation/FunctionsAsString.php';
|
||||||
|
}
|
||||||
|
}
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class DateDifTest extends TestCase
|
class DateDifTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -27,7 +27,7 @@ class DateDifTest extends TestCase
|
||||||
public function testDATEDIF($expectedResult, $startDate, $endDate, $unit)
|
public function testDATEDIF($expectedResult, $startDate, $endDate, $unit)
|
||||||
{
|
{
|
||||||
$result = DateTime::DATEDIF($startDate, $endDate, $unit);
|
$result = DateTime::DATEDIF($startDate, $endDate, $unit);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDATEDIF()
|
public function providerDATEDIF()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class DateTest extends TestCase
|
class DateTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -27,7 +27,7 @@ class DateTest extends TestCase
|
||||||
public function testDATE($expectedResult, $year, $month, $day)
|
public function testDATE($expectedResult, $year, $month, $day)
|
||||||
{
|
{
|
||||||
$result = DateTime::DATE($year, $month, $day);
|
$result = DateTime::DATE($year, $month, $day);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDATE()
|
public function providerDATE()
|
||||||
|
@ -40,7 +40,8 @@ class DateTest extends TestCase
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_UNIX_TIMESTAMP);
|
Functions::setReturnDateType(Functions::RETURNDATE_UNIX_TIMESTAMP);
|
||||||
|
|
||||||
$result = DateTime::DATE(2012, 1, 31);
|
$result = DateTime::DATE(2012, 1, 31);
|
||||||
$this->assertEquals(1327968000, $result, '', 1E-8);
|
$this->assertEquals(1327968000, $result);
|
||||||
|
$this->assertEqualsWithDelta(1327968000, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testDATEtoDateTimeObject()
|
public function testDATEtoDateTimeObject()
|
||||||
|
|
|
@ -10,7 +10,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class DateValueTest extends TestCase
|
class DateValueTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -26,7 +26,7 @@ class DateValueTest extends TestCase
|
||||||
public function testDATEVALUE($expectedResult, $dateValue)
|
public function testDATEVALUE($expectedResult, $dateValue)
|
||||||
{
|
{
|
||||||
$result = DateTime::DATEVALUE($dateValue);
|
$result = DateTime::DATEVALUE($dateValue);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDATEVALUE()
|
public function providerDATEVALUE()
|
||||||
|
@ -39,7 +39,8 @@ class DateValueTest extends TestCase
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_UNIX_TIMESTAMP);
|
Functions::setReturnDateType(Functions::RETURNDATE_UNIX_TIMESTAMP);
|
||||||
|
|
||||||
$result = DateTime::DATEVALUE('2012-1-31');
|
$result = DateTime::DATEVALUE('2012-1-31');
|
||||||
$this->assertEquals(1327968000, $result, '', 1E-8);
|
$this->assertEquals(1327968000, $result);
|
||||||
|
$this->assertEqualsWithDelta(1327968000, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testDATEVALUEtoDateTimeObject()
|
public function testDATEVALUEtoDateTimeObject()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class DayTest extends TestCase
|
class DayTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -26,12 +26,12 @@ class DayTest extends TestCase
|
||||||
public function testDAY($expectedResultExcel, $expectedResultOpenOffice, $dateTimeValue)
|
public function testDAY($expectedResultExcel, $expectedResultOpenOffice, $dateTimeValue)
|
||||||
{
|
{
|
||||||
$resultExcel = DateTime::DAYOFMONTH($dateTimeValue);
|
$resultExcel = DateTime::DAYOFMONTH($dateTimeValue);
|
||||||
$this->assertEquals($expectedResultExcel, $resultExcel, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResultExcel, $resultExcel, 1E-8);
|
||||||
|
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_OPENOFFICE);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_OPENOFFICE);
|
||||||
|
|
||||||
$resultOpenOffice = DateTime::DAYOFMONTH($dateTimeValue);
|
$resultOpenOffice = DateTime::DAYOFMONTH($dateTimeValue);
|
||||||
$this->assertEquals($expectedResultOpenOffice, $resultOpenOffice, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResultOpenOffice, $resultOpenOffice, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDAY()
|
public function providerDAY()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class Days360Test extends TestCase
|
class Days360Test extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -27,7 +27,7 @@ class Days360Test extends TestCase
|
||||||
public function testDAYS360($expectedResult, $startDate, $endDate, $method)
|
public function testDAYS360($expectedResult, $startDate, $endDate, $method)
|
||||||
{
|
{
|
||||||
$result = DateTime::DAYS360($startDate, $endDate, $method);
|
$result = DateTime::DAYS360($startDate, $endDate, $method);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDAYS360()
|
public function providerDAYS360()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class DaysTest extends TestCase
|
class DaysTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -26,7 +26,7 @@ class DaysTest extends TestCase
|
||||||
public function testDAYS($expectedResult, $endDate, $startDate)
|
public function testDAYS($expectedResult, $endDate, $startDate)
|
||||||
{
|
{
|
||||||
$result = DateTime::DAYS($endDate, $startDate);
|
$result = DateTime::DAYS($endDate, $startDate);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerDAYS()
|
public function providerDAYS()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class EDateTest extends TestCase
|
class EDateTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -26,7 +26,7 @@ class EDateTest extends TestCase
|
||||||
public function testEDATE($expectedResult, $dateValue, $adjustmentMonths)
|
public function testEDATE($expectedResult, $dateValue, $adjustmentMonths)
|
||||||
{
|
{
|
||||||
$result = DateTime::EDATE($dateValue, $adjustmentMonths);
|
$result = DateTime::EDATE($dateValue, $adjustmentMonths);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerEDATE()
|
public function providerEDATE()
|
||||||
|
@ -39,7 +39,8 @@ class EDateTest extends TestCase
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_UNIX_TIMESTAMP);
|
Functions::setReturnDateType(Functions::RETURNDATE_UNIX_TIMESTAMP);
|
||||||
|
|
||||||
$result = DateTime::EDATE('2012-1-26', -1);
|
$result = DateTime::EDATE('2012-1-26', -1);
|
||||||
$this->assertEquals(1324857600, $result, '', 1E-8);
|
$this->assertEquals(1324857600, $result);
|
||||||
|
$this->assertEqualsWithDelta(1324857600, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testEDATEtoDateTimeObject()
|
public function testEDATEtoDateTimeObject()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class EoMonthTest extends TestCase
|
class EoMonthTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -26,7 +26,7 @@ class EoMonthTest extends TestCase
|
||||||
public function testEOMONTH($expectedResult, $dateValue, $adjustmentMonths)
|
public function testEOMONTH($expectedResult, $dateValue, $adjustmentMonths)
|
||||||
{
|
{
|
||||||
$result = DateTime::EOMONTH($dateValue, $adjustmentMonths);
|
$result = DateTime::EOMONTH($dateValue, $adjustmentMonths);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerEOMONTH()
|
public function providerEOMONTH()
|
||||||
|
@ -39,7 +39,8 @@ class EoMonthTest extends TestCase
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_UNIX_TIMESTAMP);
|
Functions::setReturnDateType(Functions::RETURNDATE_UNIX_TIMESTAMP);
|
||||||
|
|
||||||
$result = DateTime::EOMONTH('2012-1-26', -1);
|
$result = DateTime::EOMONTH('2012-1-26', -1);
|
||||||
$this->assertEquals(1325289600, $result, '', 1E-8);
|
$this->assertEquals(1325289600, $result);
|
||||||
|
$this->assertEqualsWithDelta(1325289600, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testEOMONTHtoDateTimeObject()
|
public function testEOMONTHtoDateTimeObject()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class HourTest extends TestCase
|
class HourTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -25,7 +25,7 @@ class HourTest extends TestCase
|
||||||
public function testHOUR($expectedResult, $dateTimeValue)
|
public function testHOUR($expectedResult, $dateTimeValue)
|
||||||
{
|
{
|
||||||
$result = DateTime::HOUROFDAY($dateTimeValue);
|
$result = DateTime::HOUROFDAY($dateTimeValue);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerHOUR()
|
public function providerHOUR()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class IsoWeekNumTest extends TestCase
|
class IsoWeekNumTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -25,7 +25,7 @@ class IsoWeekNumTest extends TestCase
|
||||||
public function testISOWEEKNUM($expectedResult, $dateValue)
|
public function testISOWEEKNUM($expectedResult, $dateValue)
|
||||||
{
|
{
|
||||||
$result = DateTime::ISOWEEKNUM($dateValue);
|
$result = DateTime::ISOWEEKNUM($dateValue);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerISOWEEKNUM()
|
public function providerISOWEEKNUM()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class MinuteTest extends TestCase
|
class MinuteTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -25,7 +25,7 @@ class MinuteTest extends TestCase
|
||||||
public function testMINUTE($expectedResult, $dateTimeValue)
|
public function testMINUTE($expectedResult, $dateTimeValue)
|
||||||
{
|
{
|
||||||
$result = DateTime::MINUTE($dateTimeValue);
|
$result = DateTime::MINUTE($dateTimeValue);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerMINUTE()
|
public function providerMINUTE()
|
||||||
|
|
|
@ -9,7 +9,7 @@ use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
class MonthTest extends TestCase
|
class MonthTest extends TestCase
|
||||||
{
|
{
|
||||||
public function setUp()
|
protected function setUp(): void
|
||||||
{
|
{
|
||||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||||
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
Functions::setReturnDateType(Functions::RETURNDATE_EXCEL);
|
||||||
|
@ -25,7 +25,7 @@ class MonthTest extends TestCase
|
||||||
public function testMONTH($expectedResult, $dateTimeValue)
|
public function testMONTH($expectedResult, $dateTimeValue)
|
||||||
{
|
{
|
||||||
$result = DateTime::MONTHOFYEAR($dateTimeValue);
|
$result = DateTime::MONTHOFYEAR($dateTimeValue);
|
||||||
$this->assertEquals($expectedResult, $result, '', 1E-8);
|
$this->assertEqualsWithDelta($expectedResult, $result, 1E-8);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function providerMONTH()
|
public function providerMONTH()
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue