category |
Zend |
package |
Zend_Auth |
copyright |
Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com) |
license |
New BSD License |
Methods
Sets the result code, identity, and failure messages
__construct(integer $code, mixed $identity, array $messages = array()
)
Parameters
$code
integer
$identity
mixed
$messages
array
getCode() - Get the result code for this authentication attempt
getCode() : integer
Returns the identity used in the authentication attempt
getIdentity() : mixed
Returns an array of string reasons why the authentication attempt was unsuccessful
getMessages() : array
If authentication was successful, this method returns an empty array.
Returns
array
Returns whether the result represents a successful authentication attempt
isValid() : boolean
Properties
Authentication result code
$_code : integer
The identity used in the authentication attempt
$_identity : mixed
An array of string reasons why the authentication attempt was unsuccessful
$_messages : array
If authentication was successful, this should be an empty array.
Constants
General Failure
FAILURE = 0
Failure due to invalid credential being supplied.
FAILURE_CREDENTIAL_INVALID = -3
Failure due to identity being ambiguous.
FAILURE_IDENTITY_AMBIGUOUS = -2
Failure due to identity not being found.
FAILURE_IDENTITY_NOT_FOUND = -1
Failure due to uncategorized reasons.
FAILURE_UNCATEGORIZED = -4
Authentication success.
SUCCESS = 1