public function __construct($dividend) { if (!is_numeric($dividend) || (int) $dividend != $dividend) { $message = 'Dividend %s must be an integer'; throw new ComponentException(sprintf($message, RuleException::stringify($dividend))); } $this->dividend = (int) $dividend; }