public function setEmail($email)
    {
        if (filter_var($email, FILTER_VALIDATE_EMAIL)) {
            $this->_options['email'] = $email;
            $this->_options['hash'] = strtolower(md5(trim($this->_options['email'])));
        } else {
            throw new \Exception('The email is in an invalid format!');
        }

        return $this;
    }
public function setEmail($email)
    {
        if (filter_var($email, FILTER_VALIDATE_EMAIL)) {
            $this->_options['email'] = $email;
            $this->_options['hash'] = strtolower(md5(trim($this->_options['email'])));
        } else {
            throw new \Exception('The email is in an invalid format!');
        }

        return $this;
    }
public function setEmail ( $ email ) { if ( filter_var ( $ email , FILTER_VALIDATE_EMAIL ) ) { $ this -> _options [ 'email' ] = $ email ; $ this -> _options [ 'hash' ] = strtolower ( md5 ( trim ( $ this -> _options [ 'email' ] ) ) ) ; } else { throw new \ Exception ( 'The email is in an invalid format!' ) ; } return $ this ; }
Sets the email you want to use for image generation.

@param string $email - The email to use

@throws \Exception

@return \Pazuzu156\Gravatar\Gravatar
Sets the email you want to use for image generation .