* $options = new ezcMailComposerOptions(); * $options->automaticImageInclude = false; // default value is true * * $mail = new ezcMailComposer( $options ); * * * Alternatively, you can set the options direcly: * * $mail = new ezcMailComposer(); * $mail->options->automaticImageInclude = false; * * * @property bool $automaticImageInclude * Specifies whether to include in the generated mail the content of * the files specified with "file://" in image tags. Default value * is true (the contents are included). * * @package Mail * @version 1.5.1 */ class ezcMailComposerOptions extends ezcBaseOptions { /** * Constructs an object with the specified values. * * @throws ezcBasePropertyNotFoundException * if $options contains a property not defined * @throws ezcBaseValueException * if $options contains a property with a value not allowed * @param array(string=>mixed) $options */ public function __construct( array $options = array() ) { $this->automaticImageInclude = true; // default is to include the contents of "file://" from image tags parent::__construct( $options ); } /** * Sets the option $propertyName to $propertyValue. * * @throws ezcBasePropertyNotFoundException * if the property $propertyName is not defined * @throws ezcBaseValueException * if $propertyValue is not correct for the property $propertyName * @param string $propertyName * @param mixed $propertyValue * @ignore */ public function __set( $propertyName, $propertyValue ) { switch ( $propertyName ) { case 'automaticImageInclude': if ( !is_bool( $propertyValue ) ) { throw new ezcBaseValueException( $propertyName, $propertyValue, 'bool' ); } $this->properties[$propertyName] = $propertyValue; break; default: throw new ezcBasePropertyNotFoundException( $propertyName ); } } } ?>