PHP Class Learner\Http\Controllers\Auth\AuthController

Inheritance: extends Learner\Http\Controllers\BaseController
Datei anzeigen Open project: RryLee/learner.video

Protected Properties

Property Type Description
$roles Learner\Repositories\RoleRepositoryInterface Role Repository.
$users Learner\Repositories\UserRepositoryInterface User Repository.

Public Methods

Method Description
__construct ( Learner\Repositories\UserRepositoryInterface $users, Learner\Repositories\RoleRepositoryInterface $roles ) : void Create a new authentication controller instance.
getLogin ( ) : Illuminate\Http\Response Show the application login form.
getLogout ( ) : Illuminate\Http\Response Log the user out of the application.
getRegister ( ) : Illuminate\Http\Response Show the application register form.
postLogin ( Illuminate\Http\Request $request ) : Illuminate\Http\Response Handle a login request to the application.
postRegister ( ) : Illuminate\Http\Response Handle a registration request for the application.

Protected Methods

Method Description
create ( array $data ) : User Create a new user instance after a valid registration.
getCredentials ( Illuminate\Http\Request $request ) : array Get the needed authorization credentials from the request.
loginUsername ( ) : string Get the login username to be used by the controller.

Method Details

__construct() public method

Create a new authentication controller instance.
public __construct ( Learner\Repositories\UserRepositoryInterface $users, Learner\Repositories\RoleRepositoryInterface $roles ) : void
$users Learner\Repositories\UserRepositoryInterface
$roles Learner\Repositories\RoleRepositoryInterface
return void

create() protected method

Create a new user instance after a valid registration.
protected create ( array $data ) : User
$data array
return Learner\Models\User

getCredentials() protected method

Get the needed authorization credentials from the request.
protected getCredentials ( Illuminate\Http\Request $request ) : array
$request Illuminate\Http\Request
return array

getLogin() public method

Show the application login form.
public getLogin ( ) : Illuminate\Http\Response
return Illuminate\Http\Response

getLogout() public method

Log the user out of the application.
public getLogout ( ) : Illuminate\Http\Response
return Illuminate\Http\Response

getRegister() public method

Show the application register form.
public getRegister ( ) : Illuminate\Http\Response
return Illuminate\Http\Response

loginUsername() protected method

Get the login username to be used by the controller.
protected loginUsername ( ) : string
return string

postLogin() public method

Handle a login request to the application.
public postLogin ( Illuminate\Http\Request $request ) : Illuminate\Http\Response
$request Illuminate\Http\Request
return Illuminate\Http\Response

postRegister() public method

Handle a registration request for the application.
public postRegister ( ) : Illuminate\Http\Response
return Illuminate\Http\Response

Property Details

$roles protected_oe property

Role Repository.
protected RoleRepositoryInterface,Learner\Repositories $roles
return Learner\Repositories\RoleRepositoryInterface

$users protected_oe property

User Repository.
protected UserRepositoryInterface,Learner\Repositories $users
return Learner\Repositories\UserRepositoryInterface