UserToken::model PHP Method

model() public static method

Please note that you should have this exact method in all your CActiveRecord descendants!
public static model ( string $className = __CLASS__ ) : UserToken
$className string active record class name.
return UserToken the static model class
    public static function model($className = __CLASS__)
    {
        return parent::model($className);
    }

Usage Example

 public function loadModel($id)
 {
     if (($model = UserToken::model()->findByPk($id)) === null) {
         throw new CHttpException(404, 'Страница не найдена');
     }
     return $model;
 }
All Usage Examples Of UserToken::model