コード例 #1
0
 public static function checkInt($i, $name)
 {
     if (!Check::isInt($i)) {
         throw new \InvalidArgumentException('\'' . $name . '\' must be an integer number but was \'' . var_export($i, true) . '\'');
     }
 }
コード例 #2
0
ファイル: Check.php プロジェクト: purchased-at/sdk-php
 public static function isIntRange($i, $min = PHP_INT_MIN, $max = PHP_INT_MAX)
 {
     return Check::isInt($i) && $i >= $min && $i <= $max;
 }