Add a message to the exception's existing message. Used to add additional information to an existing message.

@param  string $message

@return $this
163434
public function addMessage($message) {
        $this->message = trim(trim($this->message).NL.$message);
        return $this;
    }
86837
public function appendCustomMessage($message)
    {
        $customMessage = $this->getHTMLDocument()->getHTMLFactory()->buildHtmlElement('div', $message, '', 'custom-message');

        return $this->append($customMessage);
    }
256643
public function add($message = null, $type = 'notice')
    {
        if (!isset($this->messages[$type]) || !is_array($this->messages[$type])) {
            $this->messages[$type] = [];
        }
        if ($message) {
            $this->messages[$type][] = $message;
        }
        $this->writeToSession();
        return $this;
    }
32374
public static function forMessage(Message $message)
    {
        $exception = new static('Missing publisher for message of class ' . get_class($message));
        $exception->tacticianMessage = $message;

        return $exception;
    }
1279693
protected function addError(\Exception $exception)
    {
        $this->errorList[$exception->getCode()] = [
            'message'   => $exception->getMessage(),
            'line'      => $exception->getLine(),
            'file'      => $exception->getFile(),
            'trace'     => $exception->getTraceAsString(),
        ];
        $this->hasErrors = true;

        return $this;
    }
251268
public function skip($message = '')
    {
        if ($this->skipped !== true) {
            $this->skipped = true;
            $this->skipped_because = $message;
        }

        return $this;
    }
817898
public function write($message)
    {
        if (!$this->logFile) {
            throw new \Parable\Log\Exception("No log file set. \Log\Writer\File requires a valid target file.");
        }
        $this->writeToFile($message);
        return $this;
    }
1253485
public function setText($message) {
        if (empty($message)) {
            throw new \InvalidArgumentException('Message cannot be empty');
        }

        $this->message->setText($message);
        return $this;
    }
1132537
public function addLog($key, $message)
    {
        if (!is_string($message)) {
            throw new \InvalidArgumentException(sprintf(
                '[%s]: "message" must be type of string, %s given.',
                __METHOD__,
                gettype($message)
            ));
        }

        if (!isset($this->logs[$key])) {
            $this->logs[$key] = [];
        }

        $this->logs[$key][] = $message;

        return $this;
    }
124578
public function message($message)
    {
        if (is_string($message) || is_numeric($message)) {
            $message = new Text($message);
        }

        if (!($message instanceof Message)) {
            throw new InvalidArgumentException('Invalid message.');
        }

        $this->message = $message;

        return $this;
    }
1371407
final public function setErrorMessage($message)
    {
        $this->errorMessage = (string) $message;

        if (empty($this->errorMessage)) {
            throw new \RuntimeException('Error message cannot be empty !');
        }

        return $this;
    }
1328175
public function addMessage(Message $message)
    {
        $message->setMessageBroker($this);
        $this->messages->attach($message);
    }
182904
public function add_error($message, $field = null)
    {
        $message = array_values((array)$message);

        // Save the error message
        if (isset($field)) {
            $this->_field_data[$field]['error'] = $message[0];
        }
        $this->_error_array = array_merge($this->_error_array, $message);
        return $this;
    }
529348
function setMessage($message)
    {
        if ($this->isAnonymous()) {
            throw new Pluf_Exception_DoesNotExist(__("User not exist, while you are trying to add message?!"));
        }
        $m = new User_Message();
        $m->account_id = $this;
        $m->message = $message;
        if (! $m->create()) {
            throw new Pluf_Exception(__("not possible to create a message"));
        }
        return $m;
    }
895505
public function add(Message $message)
    {
        $this->queue->insert($message, is_null($message->getPosition()) ? null : -$message->getPosition());

        $this->copyQueue(clone $this->queue);

        return $this;
    }
1053560
public function addMessage(Message $message): Email
    {
        if (null === $this->message->getBody()) {
            $this->message->setBody($message->getBody(), $message->getContentType());

            return $this;
        }

        $this->message->addPart($message->getBody(), $message->getContentType());

        return $this;
    }
673485
public function add($message, $scope = 'default')
    {
        $key = md5($scope.'~'.$message);
        $item = ['message' => $message, 'scope' => $scope];

        // don't add duplicates
        if (!array_key_exists($key, $this->messages)) {
            $this->messages[$key] = $item;
        }

        return $this;
    }