$status
$status :
__construct(boolean $status = false, string $message = "", array $values = array(), array $secvalues = array())
construct a new instance of the result object
boolean | $status | The boolean state of the initialised status |
string | $message | The first message |
array | $values | The initial result data set |
array | $secvalues | The initial secondary result data set |
SetErrorMessage(string $msg, array $var = null)
Set error message
Convenience function to set message and status at once Set the message and the status to false
string | $msg | The new message |
array | $var | An associative array with variable parameters to parse into the translation |
setError(string|array $key, string $val = '', array $var = null)
Set new error Can set an array of errors or a assoc error entry
string|array | $key | The key of the message |
string | $val | The Value of the message |
array | $var | An associative array with variable parameters to parse into the translation |
SetResponses(\FAA\Obj\Result $result, boolean $full = false)
Merge error result Merge with other error result object
\FAA\Obj\Result | $result | The other result |
boolean | $full | Also merge data on demand |
GetAssoc(integer $format = FAA_RESULT_TYPE_PLAIN, string $l = '', boolean $empty_null = false) : array
get the data get all the data as assoc array
integer | $format | The result format type |
string | $l | The result language |
boolean | $empty_null | When true, empty values will be skipped |
The associative representation of this object
getErrors(integer $format = FAA_RESULT_TYPE_PLAIN, string $l = '') : array|string
get the error messages Translate errors or get plain data.
integer | $format | The result format type |
string | $l | The result language |
Either the plain set of errors or a translated message
getMessage(integer $format = FAA_RESULT_TYPE_PLAIN, string $l = '') : array|string
get the messages Translate errors or get plain data.
integer | $format | The result format type |
string | $l | The result language |
Either the plain set of errors or a translated message
map(array $assoc, string $l = '') : string
map and translate data create a readable result string from a given set of result templates
array | $assoc | A combined text with arguments to map |
string | $l | The target translation language code or false in plain mode |
The mapped translated template with parsed args