Beispiel #1
0
 /**
  * Allows caller to have the mail subject dynamically set to contain the
  * entry counts per-priority level.
  *
  * Sets the text for use in the subject, with entry counts per-priority
  * level appended to the end.  Since a Zend_Mail subject can only be set
  * once, this method cannot be used if the Zend_Mail object already has a
  * subject set.
  *
  * @param  string $subject Subject prepend text.
  * @throws \Zend\Log\Exception\RuntimeException
  * @return \Zend\Log\Writer\Mail
  */
 public function setSubjectPrependText($subject)
 {
     if ($this->_mail->getSubject()) {
         throw new Log\Exception\RuntimeException('subject already set on mail; ' . 'cannot set subject prepend text');
     }
     $this->_subjectPrependText = (string) $subject;
     return $this;
 }