GuardHelpers::id()

int|null id() Get the ID for the currently authenticated user. Return Value int|null

GuardHelpers::guest()

bool guest() Determine if the current user is a guest. Return Value bool

GuardHelpers::check()

bool check() Determine if the current user is authenticated. Return Value bool

GuardHelpers::authenticate()

Authenticatable authenticate() Determine if the current user is authenticated. Return Value Authenticatable Exceptions AuthenticationException

GuardHelpers

GuardHelpers trait GuardHelpers (View source) These methods are typically the same across all guards. Methods Authenticatable authenticate() Determine if the current user is authenticated. bool check() Determine if the current user is authenticated. bool guest() Determine if the current user is a guest. int|null id() Get the ID for the currently authenticated user. $this setUser(Authenticatable $user) Set the current user.

Guard::__construct()

void __construct(HttpKernelInterface $app, Encrypter $encrypter) Create a new CookieGuard instance. Parameters HttpKernelInterface $app Encrypter $encrypter Return Value void

Guard::__construct()

void __construct(UserProvider $provider, SessionInterface $session, Request $request = null) Create a new authentication guard. Parameters UserProvider $provider SessionInterface $session Request $request Return Value void

Guard::viaRemember()

bool viaRemember() Determine if the user was authenticated via "remember me" cookie. Return Value bool

Guard::validate()

bool validate(array $credentials = array()) Validate a user's credentials. Parameters array $credentials Return Value bool

Guard::validate()

bool validate(array $credentials = array()) Validate a user's credentials. Parameters array $credentials Return Value bool