StatefulGuard
interface StatefulGuard implements Guard (View source)
Methods
Attempt to authenticate a user using the given credentials.
Log a user into the application without sessions or cookies.
Log the given user ID into the application.
Log the given user ID into the application without sessions or cookies.
Determine if the user was authenticated via "remember me" cookie.
Log the user out of the application.
Details
in
Guard at line 12
bool
check()
Determine if the current user is authenticated.
in
Guard at line 19
bool
guest()
Determine if the current user is a guest.
in
Guard at line 26
Authenticatable|null
user()
Get the currently authenticated user.
in
Guard at line 33
int|string|null
id()
Get the ID for the currently authenticated user.
in
Guard at line 41
bool
validate(array $credentials = [])
Validate a user's credentials.
in
Guard at line 48
bool
hasUser()
Determine if the guard has a user instance.
in
Guard at line 56
$this
setUser(Authenticatable $user)
Set the current user.
bool
attempt(array $credentials = [], bool $remember = false)
Attempt to authenticate a user using the given credentials.
bool
once(array $credentials = [])
Log a user into the application without sessions or cookies.
void
login(Authenticatable $user, bool $remember = false)
Log a user into the application.
Authenticatable|false
loginUsingId(mixed $id, bool $remember = false)
Log the given user ID into the application.
Authenticatable|false
onceUsingId(mixed $id)
Log the given user ID into the application without sessions or cookies.
bool
viaRemember()
Determine if the user was authenticated via "remember me" cookie.
void
logout()
Log the user out of the application.