Set rule message for current field

@param string $ruleOrMessage
@param string|null $message
@return $this
332220
public function message($ruleOrMessage, $message = null)
    {
        if (1 === func_num_args()) {
            $rule = $this->lastRule;
            $message = $ruleOrMessage;
        } else {
            $rule = $ruleOrMessage;
        }

        $this->options['messages'][$this->lastKey][$rule] = $message;

        return $this;
    }
949090
public function addValidationRule($rule, $message = null)
    {
        $uploadRules = ['file', 'image', 'mime', 'size', 'dimensions', 'max', 'min', 'between'];

        foreach ($uploadRules as $uploadRule) {
            if (strpos($rule, $uploadRule) !== false) {
                $this->uploadValidationRules[] = $rule;

                if (is_null($message)) {
                    return $this;
                }

                return $this->addValidationMessage($rule, $message);
            }
        }

        return parent::addValidationRule($rule, $message);
    }
950340
public function setMessage($message)
    {
        if ( ! is_null($message)) $message = (string) $message;

        $this->setAttribute('message', $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;
    }
13731
public function setMessageArg($messageArg)
    {

        $messageArg = (array) $messageArg;

        /**
         * Check on empty argument and check if
         * passed argument is not equal to existence
         */
        if (empty($messageArg)
            || $this->getData(self::P_MESSAGE_ARG) === $messageArg
        ) {
            return null;
        }

        $formattedMessage = vsprintf($this->message, $messageArg);

        if ($formattedMessage === $this->message) {
            // there are no any %s so we just append params
            $formattedMessage = ' [' . implode('] [', $messageArg) . ']';
        }
        $this->message = $formattedMessage;

        $this->data[self::P_MESSAGE_ARG] = $messageArg;

        return $this;
    }
12197
public function addError($fieldName, $ruleName, $message)
    {
        $this->errors[$fieldName][$ruleName] = $message;

        return $this;
    }
235110
public static function set_error_message($rule, $message)
    {
        $gump = self::get_instance();
        self::$validation_methods_errors[$rule] = $message;
    }
610649
protected function formatMessage($parameter, $ruleName, $ruleParameter, $message = null)
    {
        $message = $message ?: (isset($this->validateMessages[$ruleName]) ? $this->validateMessages[$ruleName] : $this->validateMessages['default']);
        $message = str_replace(':parameter', $parameter, $message);
        $method  = 'format'.ucfirst(Helper::camelCase($ruleName)).'Message';

        if (method_exists($this, $method)) {
            return $this->$method($ruleParameter, $message);
        }

        return $message;
    }
569994
public function setMessageId($message)
    {
        if (is_bool($message)) {
            $this->_messageId = $message;
        } else {
            if (!preg_match('/^\<.+@.+\>$/', $message)) {
                throw new InvalidArgumentException('Invalid format to Message-ID. The text should be something like "<uuid@server.com>"');
            }
            $this->_messageId = $message;
        }

        return $this;
    }
778131
public function setPostMessageTemplate($postMessage = null)
    {
        if (null !== $postMessage) {
            $postMessage = (string) $postMessage;
        }
        $this->abstractOptions['messageTemplates']
                              [self::POST_MESSAGE_TEMPLATE_KEY] = $postMessage;
        return $this;
    }
1124625
public function getMessage($key, $rule, $message = null) {
        $label = isset($this->labels[$key]) ? $this->labels[$key] : $key;
        if (!is_null($message)) {
            return str_replace(':attribute', $label, $message);
        }
        if (isset($this->messages[$key.'.'.$rule])) {
            return $this->messages[$key.'.'.$rule];
        }
        return str_replace(':attribute', $label, $this->messages[$rule]);
    }
1020550
public function setMessage($message, $priority)
    {
        $this->message = (string) $message;
        $this->priority = (int) $priority;
    }
928553
public function setErrorMessage($errorMessage)
    {
        $this->errorMessage = $errorMessage;
        $this->setValidator($this->getDefaultValidator());

        return $this;
    }
715622
protected function assertFalse($condition, $message = null)
    {
        $this->context->assertFalse($condition, $message);

        return $this;
    }
917286
public function setError($field, $message) {

    	$instance = $this -> getMessageInstance();

    	$instance :: setFieldnames([$field]);
		$instance :: setError($this -> getPrefix(), $field, $message);

		$this -> setPasses(false);

    	return $this;
    }
1342746
public function mixin($ruleName, $validator, $message = '')
	{
        if ( ! empty($message))
        {
            $this->messages[$ruleName] = $message;
        }
        Validator::extend($ruleName, $validator);

		return $this;
	}
534426
public function setStatusMessage($message)
    {
        if($entity = $this->getIterator()->current()) {
            $entity->setStatusMessage($message);
        }

        return $this;
    }