Passed
Push — master ( d898ef...46a72e )
by Christopher
02:06 queued 27s
created

xsDouble::isOK()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
namespace AlgoWeb\xsdTypes;
4
5
/**
6
 * The type xsd:double represents an IEEE double-precision 64-bit floating-point number. The format of xsd:double
7
 * values is a mantissa (a number which conforms to the type decimal) followed, optionally, by the character "E"
8
 * or "e" followed by an exponent. The exponent must be an integer. For example, 3E2 represents 3 times 10 to the
9
 * 2nd power, or 300. The exponent must be an integer.
10
 *
11
 * In addition, the following values are valid: INF (infinity), -INF (negative infinity), and NaN (Not a Number).
12
 * INF is considered to be greater than all other values, while -INF is less than all other values. The value NaN
13
 * cannot be compared to any other values, although it equals itself.
14
 * @package AlgoWeb\xsdTypes
15
 */
16
class xsDouble extends xsAnySimpleType
17
{
18
    use MinMaxTrait;
19
20
    /**
21
     * Construct
22
     *
23
     * @param double $value
24
     */
25
    public function __construct($value)
26
    {
27
        parent::__construct($value);
28
        $this->setWhiteSpaceFacet("collapse");
29
    }
30
31
    protected function isOK()
32
    {
33
        $this->CheckMinMax($this->__value);
34
    }
35
}
36