ILIAS
release_5-4 Revision v5.4.26-12-gabc799a52e6
◀ ilDoc Overview
Compare.php
Go to the documentation of this file.
1
<?
php
2
3
namespace
PhpOffice\PhpSpreadsheet\Calculation\Engineering
;
4
5
use
PhpOffice\PhpSpreadsheet\Calculation\Exception
;
6
use
PhpOffice\PhpSpreadsheet\Calculation\Functions
;
7
8
class
Compare
9
{
26
public
static
function
DELTA
($a, $b = 0)
27
{
28
$a =
Functions::flattenSingleValue
($a);
29
$b =
Functions::flattenSingleValue
($b);
30
31
try
{
32
$a =
EngineeringValidations::validateFloat
($a);
33
$b =
EngineeringValidations::validateFloat
($b);
34
}
catch
(
Exception
$e) {
35
return
$e->getMessage();
36
}
37
38
return
(
int
) ($a == $b);
39
}
40
56
public
static
function
GESTEP
($number,
$step
= 0)
57
{
58
$number =
Functions::flattenSingleValue
($number);
59
$step
=
Functions::flattenSingleValue
(
$step
);
60
61
try
{
62
$number =
EngineeringValidations::validateFloat
($number);
63
$step
=
EngineeringValidations::validateFloat
(
$step
);
64
}
catch
(
Exception
$e) {
65
return
$e->getMessage();
66
}
67
68
return
(
int
) ($number >=
$step
);
69
}
70
}
PhpOffice\PhpSpreadsheet\Calculation\Engineering\Compare\DELTA
static DELTA($a, $b=0)
DELTA.
Definition:
Compare.php:26
PhpOffice\PhpSpreadsheet\Calculation\Engineering\Compare\GESTEP
static GESTEP($number, $step=0)
GESTEP.
Definition:
Compare.php:56
$step
foreach( $_REQUEST as $var) foreach(array('_POST'=> 'HTTP_POST_VARS', '_GET'=> 'HTTP_GET_VARS', '_COOKIE'=> 'HTTP_COOKIE_VARS', '_SERVER'=> 'HTTP_SERVER_VARS', '_ENV'=> 'HTTP_ENV_VARS', '_FILES'=> 'HTTP_POST_FILES') as $array=> $other) $step
Definition:
cssgen.php:155
Exception
PhpOffice\PhpSpreadsheet\Calculation\Engineering
Definition:
BesselI.php:3
PhpOffice\PhpSpreadsheet\Calculation\Engineering\Compare
Definition:
Compare.php:8
Functions
PhpOffice\PhpSpreadsheet\Calculation\Engineering\EngineeringValidations\validateFloat
static validateFloat($value)
Definition:
EngineeringValidations.php:13
php
PhpOffice\PhpSpreadsheet\Calculation\Functions\flattenSingleValue
static flattenSingleValue($value='')
Convert an array to a single scalar value by extracting the first element.
Definition:
Functions.php:649
Exception
libs
composer
vendor
phpoffice
phpspreadsheet
src
PhpSpreadsheet
Calculation
Engineering
Compare.php
Generated on Thu Jan 30 2025 19:01:22 for ILIAS by
1.8.13 (using
Doxyfile
)