Documentation

User extends Base

Table of Contents

$entityManager  : EntityManager
$queryBuilder  : QueryBuilder
$request  : Request
$router  : Router
$view  : Json
__construct()  : mixed
create()  : User
Creates new user
getAll()  : array<string|int, array<string|int, mixed>>
Returns all users
getState()  : array<string|int, string>
Returns API state
login()  : User
Verifi user credentials
registerDefaultRoutes()  : void
Register default routes
registerRoutes()  : void
Register routes to router
requestDispatch()  : void
Dispatch request to predefined routes
setRequest()  : void
Sets request
setView()  : void
Sets view
checkPerms()  : void
Checks user permitions on route action

Properties

$entityManager

protected EntityManager $entityManager

$queryBuilder

protected QueryBuilder $queryBuilder

Methods

__construct()

public __construct(EntityManager $entityManager) : mixed
Parameters
$entityManager : EntityManager
Return values
mixed

create()

Creates new user

public create() : User
Return values
User

getAll()

Returns all users

public getAll() : array<string|int, array<string|int, mixed>>
Return values
array<string|int, array<string|int, mixed>>

getState()

Returns API state

public getState() : array<string|int, string>
Tags
todo

Make it usefull

Return values
array<string|int, string>

login()

Verifi user credentials

public login() : User
Return values
User

registerDefaultRoutes()

Register default routes

public registerDefaultRoutes(Router $router) : void
Parameters
$router : Router
Return values
void

registerRoutes()

Register routes to router

public registerRoutes(Router $router) : void
Parameters
$router : Router
Return values
void

requestDispatch()

Dispatch request to predefined routes

public requestDispatch(Router $router, Request $request) : void
Parameters
$router : Router
$request : Request
Return values
void

setRequest()

Sets request

public setRequest(Request $request) : void
Parameters
$request : Request
Return values
void

setView()

Sets view

public setView(string $view) : void
Parameters
$view : string
Return values
void

checkPerms()

Checks user permitions on route action

private checkPerms(Route $route) : void
Parameters
$route : Route
Return values
void

Search results