public function getIntParam($name, $default = null, $optional = false)
    {
        $value = $this->getParam($name, $default, $optional);
        if ($value !== null) {
            if (!preg_match('/^\-?\d*$/', $value)) {
                throw new InvalidParameterException("Parameter '{$name}' is invalid");
            }
            $value = (int)$value;
        }
        return $value;
    }
public function getIntParam($name, $default = null, $optional = false)
    {
        $value = $this->getParam($name, $default, $optional);
        if ($value !== null) {
            if (!preg_match('/^\-?\d*$/', $value)) {
                throw new InvalidParameterException("Parameter '{$name}' is invalid");
            }
            $value = (int)$value;
        }
        return $value;
    }
public function getIntParam ( $ name , $ default = null , $ optional = false ) { $ value = $ this -> getParam ( $ name , $ default , $ optional ) ; if ( $ value !== null ) { if ( ! preg_match ( '/^\-?\d*$/' , $ value ) ) { throw new InvalidParameterException ( "Parameter '{$name}' is invalid" ) ; } $ value = ( int ) $ value ; } return $ value ; }
Returns the value of the specified parameter as an integer value.

@param string $name
@param int    $default
@param bool   $optional
@return int
@throws InvalidParameterException
Returns the value of the specified parameter as an integer value .