trait
Illuminate
/
Auth
/
GuardHelpers
You are viewing an older version of the documentation. For the latest, please visit master documentation.
GuardHelpers
Properties
Methods
public
authenticate ( ) : Authenticatable
Determine if the current user is authenticated. If not, throw an exception.
public
hasUser ( ) : bool
Determine if the guard has a user instance.
public
check ( ) : bool
Determine if the current user is authenticated.
public
guest ( ) : bool
Determine if the current user is a guest.
public
id ( ) : int|string|null
Get the ID for the currently authenticated user.
public
setUser ( Authenticatable $user ) : $this
Set the current user.
Parameters
- $user Authenticatable
public
setProvider ( UserProvider $provider ) : void
Set the user provider used by the guard.
Parameters
- $provider UserProvider