PHP Class Webiny\Component\Security\User\Providers\OAuth2\OAuth2Event

Inheritance: extends Webiny\Component\EventManager\Event
Show file Open project: Webiny/Framework

Public Methods

Method Description
__construct ( OAuth2User $OAuth2User, OAuth2 $OAuth2 ) Base constructor.
getOAuth2Instance ( ) : OAuth2 Get OAuth2 instance used to authenticate the user.
getUser ( ) : null | OAuth2User Returns current user.

Method Details

__construct() public method

Base constructor.
public __construct ( OAuth2User $OAuth2User, OAuth2 $OAuth2 )
$OAuth2User Webiny\Component\OAuth2\OAuth2User The current user.
$OAuth2 Webiny\Component\OAuth2\OAuth2 OAuth2 class, containing the access key.

getOAuth2Instance() public method

It holds an active access key.
public getOAuth2Instance ( ) : OAuth2
return Webiny\Component\OAuth2\OAuth2

getUser() public method

Returns current user.
public getUser ( ) : null | OAuth2User
return null | Webiny\Component\OAuth2\OAuth2User