-
| $raw |
false to use it as arguments for the message format, true otherwise (default to false) |
Returns the arguments needed to format the message.
-
(string) getMessageFormat ()
Browse code
Returns the message format for this error.
This is the string you need to use if you need to internationalize
error messages:
$i18n->__($error->getMessageFormat(), $error->getArguments());
If no message format has been set in the validator, the exception standard
message is returned.
returns The message format
-
(sfValidatorBase) getValidator ()
Browse code
Returns the validator that triggered this error.
returns A sfValidatorBase instance
-
Returns the input value that triggered this error.
returns The input value
-
Serializes the current instance.
We must implement the Serializable interface to overcome a problem with PDO
used as a session handler.
The default serialization process serializes the exception trace, and because
the trace can contain a PDO instance which is not serializable, serializing won't
work when using PDO.
returns The instance as a serialized string
-
unserialize ($serialized)
Browse code
| $serialized |
A serialized sfValidatorError instance |
Unserializes a sfValidatorError instance.
-
__construct ($validator, $code, $arguments)
Browse code
| $validator |
An sfValidatorBase instance |
| $code |
The error code |
| $arguments |
An array of named arguments needed to render the error message |
Constructor.
-
(string) __toString ()
Browse code
Returns the string representation of the error.
returns The error message