1) { throw new InvalidArgumentException('No more than 1 argument is expected'); } $floatValue = ArrayUtils::get($arguments, 0); if (is_string($floatValue) || $floatValue === null) { $this->addValues($floatValue); return $this; } if (! is_numeric($floatValue)) { if (!method_exists($floatValue, '__toString')) { throw new InvalidArgumentException("Argument should be a number or a string"); } throw new InvalidArgumentException("'$floatValue' should be a number or a string"); } if ($floatValue < 0) { throw new InvalidArgumentException("'$floatValue' should be greater than zero"); } if (is_int($floatValue)) { $floatValue .= '.0'; } $this->addValues($floatValue); return $this; } }