Interface yii\debug\models\search\UserSearchInterface

Extendsyii\web\IdentityInterface
Available since version2.0.10
Source Code https://github.com/yiisoft/yii2-debug/blob/master/models/search/UserSearchInterface.php

UserSearchInterface is the interface that should be implemented by a class providing identity information and search method.

Public Methods

Hide inherited methods

Method Description Defined By
findIdentity() Finds an identity by the given ID. yii\web\IdentityInterface
findIdentityByAccessToken() Finds an identity by the given token. yii\web\IdentityInterface
getAuthKey() Returns a key that can be used to check the validity of a given identity ID. yii\web\IdentityInterface
getId() Returns an ID that can uniquely identify a user identity. yii\web\IdentityInterface
search() Creates data provider instance with search query applied. yii\debug\models\search\UserSearchInterface
validateAuthKey() Validates the given auth key. yii\web\IdentityInterface

Method Details

Hide inherited methods

findIdentity() public abstract static method

Defined in: yii\web\IdentityInterface::findIdentity()

Finds an identity by the given ID.

public abstract static yii\web\IdentityInterface|null findIdentity ( $id )
$id string|integer

The ID to be looked for

return yii\web\IdentityInterface|null

The identity object that matches the given ID. Null should be returned if such an identity cannot be found or the identity is not in an active state (disabled, deleted, etc.)

                public static function findIdentity($id);

            
findIdentityByAccessToken() public abstract static method

Defined in: yii\web\IdentityInterface::findIdentityByAccessToken()

Finds an identity by the given token.

public abstract static yii\web\IdentityInterface|null findIdentityByAccessToken ( $token, $type null )
$token mixed

The token to be looked for

$type mixed

The type of the token. The value of this parameter depends on the implementation. For example, yii\filters\auth\HttpBearerAuth will set this parameter to be yii\filters\auth\HttpBearerAuth.

return yii\web\IdentityInterface|null

The identity object that matches the given token. Null should be returned if such an identity cannot be found or the identity is not in an active state (disabled, deleted, etc.)

                public static function findIdentityByAccessToken($token, $type = null);

            
getAuthKey() public abstract method

Defined in: yii\web\IdentityInterface::getAuthKey()

Returns a key that can be used to check the validity of a given identity ID.

The key should be unique for each individual user, and should be persistent so that it can be used to check the validity of the user identity.

The space of such keys should be big enough to defeat potential identity attacks.

The returned key is used to validate session and auto-login (if yii\web\User::$enableAutoLogin is enabled).

Make sure to invalidate earlier issued authKeys when you implement force user logout, password change and other scenarios, that require forceful access revocation for old sessions.

See also validateAuthKey().

public abstract string|null getAuthKey ( )
return string|null

A key that is used to check the validity of a given identity ID.

                public function getAuthKey();

            
getId() public abstract method

Defined in: yii\web\IdentityInterface::getId()

Returns an ID that can uniquely identify a user identity.

public abstract string|integer getId ( )
return string|integer

An ID that uniquely identifies a user identity.

                public function getId();

            
search() public abstract method

Creates data provider instance with search query applied.

public abstract yii\data\DataProviderInterface search ( $params )
$params array

The data array to load model.

                public function search($params);

            
validateAuthKey() public abstract method

Defined in: yii\web\IdentityInterface::validateAuthKey()

Validates the given auth key.

See also getAuthKey().

public abstract boolean|null validateAuthKey ( $authKey )
$authKey string

The given auth key

return boolean|null

Whether the given auth key is valid.

                public function validateAuthKey($authKey);