public function addMessage($message, $type = self::FLASH_SUCCESS)
    {
        if (!is_string($message) && !(is_object($message) && method_exists($message, '__toString')))
        {
            throw new \UnexpectedValueException(
                'The flash message must be a string or object implementing __toString(), "'.gettype($message).'" given.'
            );
        }

        if(!isset($this->_messages[$type])) {
            $this->_messages[$type] = array();
        }

        $this->_messages[$type][] = $message;
        return $this;
    }