public function setWidth($width)
    {
        if (is_int($width) === true) {
            $this->width = $width;
        } else {
            $msg = "The 'width' argument must be an integer, '" . gettype($width) . "' given.";
            throw new InvalidArgumentException($msg);
        }
    }
public function setWidth($width)
    {
        if (is_int($width) === true) {
            $this->width = $width;
        } else {
            $msg = "The 'width' argument must be an integer, '" . gettype($width) . "' given.";
            throw new InvalidArgumentException($msg);
        }
    }
public function setWidth ( $ width ) { if ( is_int ( $ width ) === true ) { $ this -> width = $ width ; } else { $ msg = "The 'width' argument must be an integer, '" . gettype ( $ width ) . "' given." ; throw new InvalidArgumentException ( $ msg ) ; } }
Set the width of the object.

A negative value describes that no width is provided.

@param integer $width A width.
@throws \InvalidArgumentException
Set the width of the object .