/** * Generated from @assert (102943875019273091740987023948) === FALSE. */ public function testIsDigits3() { $this->assertSame(FALSE, Inspekt::isDigits(1.0294387501927309E+29)); }
/** * Returns value if every character is a digit, FALSE otherwise. * This is just like isInt(), except there is no upper limit. * * @param mixed $key * @return mixed * * @tag validator */ function testDigits($key) { if (!$this->keyExists($key)) { return false; } if (Inspekt::isDigits($this->_getValue($key))) { return $this->_getValue($key); } return FALSE; }
/** * Returns value if every character is a digit, FALSE otherwise. * This is just like isInt(), except there is no upper limit. * * @param mixed $key * @return mixed * @throws Exception * @tag validator */ public function testDigits($key) { $value = $this->getValueOrNull($key); if (!is_null($value) && Inspekt::isDigits($value)) { return $value; } return false; }