Class yii\debug\models\search\User
| Inheritance | yii\debug\models\search\User » yii\base\Model |
|---|---|
| Available since extension's version | 2.0.10 |
| Source Code | https://github.com/yiisoft/yii2-debug/blob/master/src/models/search/User.php |
Search model for implementation of IdentityInterface
Public Properties
| Property | Type | Description | Defined By |
|---|---|---|---|
| $identityImplement | \yii\base\Model | Implementation of IdentityInterface | yii\debug\models\search\User |
Public Methods
Property Details
Implementation of IdentityInterface
Method Details
| public __get ( mixed $name ) | ||
| $name | mixed | |
public function __get($name)
{
return $this->identityImplement->__get($name);
}
| public __set ( mixed $name, mixed $value ) | ||
| $name | mixed | |
| $value | mixed | |
public function __set($name, $value)
{
return $this->identityImplement->__set($name, $value);
}
| public attributes ( ) |
public function attributes()
{
return $this->identityImplement->attributes();
}
| public init ( ) |
public function init()
{
if (\Yii::$app->user && \Yii::$app->user->identityClass) {
$identityImplementation = new \Yii::$app->user->identityClass();
if ($identityImplementation instanceof Model) {
$this->identityImplement = $identityImplementation;
}
}
parent::init();
}
| public rules ( ) |
public function rules()
{
return [[array_keys($this->identityImplement->getAttributes()), 'safe']];
}