Bristol SU Support Package
Public Member Functions | Private Attributes | List of all members
BristolSU\Support\User\UserWebAuthentication Class Reference
Inheritance diagram for BristolSU\Support\User\UserWebAuthentication:
Inheritance graph
[legend]
Collaboration diagram for BristolSU\Support\User\UserWebAuthentication:
Collaboration graph
[legend]

Public Member Functions

 __construct (AuthFactory $auth)
 
 getUser ()
 
 setUser (User $user)
 
 logout ()
 

Private Attributes

 $auth
 

Detailed Description

Resolve users using the Laravel authentication

Definition at line 11 of file UserWebAuthentication.php.

Constructor & Destructor Documentation

◆ __construct()

BristolSU\Support\User\UserWebAuthentication::__construct ( AuthFactory  $auth)
Parameters
AuthFactory$authAuth factory for resolving and setting users with Laravel

Definition at line 24 of file UserWebAuthentication.php.

References BristolSU\Support\User\UserWebAuthentication\$auth.

Member Function Documentation

◆ getUser()

BristolSU\Support\User\UserWebAuthentication::getUser ( )

Get the currently logged in user

Returns
User|null Null if no user found

Implements BristolSU\Support\User\Contracts\UserAuthentication.

Definition at line 34 of file UserWebAuthentication.php.

◆ logout()

BristolSU\Support\User\UserWebAuthentication::logout ( )

Log out of the current user

Returns
void

Implements BristolSU\Support\User\Contracts\UserAuthentication.

Definition at line 57 of file UserWebAuthentication.php.

◆ setUser()

BristolSU\Support\User\UserWebAuthentication::setUser ( User  $user)

Set the logged in user

Parameters
User$userUser to set

Implements BristolSU\Support\User\Contracts\UserAuthentication.

Definition at line 47 of file UserWebAuthentication.php.

Member Data Documentation

◆ $auth

BristolSU\Support\User\UserWebAuthentication::$auth
private

The documentation for this class was generated from the following file: