PHP Class Owl\Repositories\Eloquent\UserRepository

Inheritance: implements Owl\Repositories\UserRepositoryInterface
Afficher le fichier Open project: owl/owl

Protected Properties

Свойство Type Description
$user

Méthodes publiques

Méthode Description
__construct ( User $user )
create ( mixed $credentials ) : Illuminate\Database\Eloquent\Model Create a new user.
getAll ( ) : Illuminate\Database\Eloquent\Collection Get all user data.
getByEmail ( string $email ) : Illuminate\Database\Eloquent\Model Get a user by email.
getById ( integer $id ) : Illuminate\Database\Eloquent\Model Get a user by user id.
getByUsername ( string $username ) : Illuminate\Database\Eloquent\Model Get a user by username.
getLikeUsername ( string $username ) : Illuminate\Database\Eloquent\Model Get users by username like search.
getOwners ( ) : Illuminate\Database\Eloquent\Model Get users which role is owner.
getUsersToArray ( $users ) : array get users array
updateUser ( integer $id, string $username, string $email, $role ) : Illuminate\Database\Eloquent\Model Update a user information(username, email, role).

Method Details

__construct() public méthode

public __construct ( User $user )
$user Owl\Repositories\Eloquent\Models\User

create() public méthode

Create a new user.
public create ( mixed $credentials ) : Illuminate\Database\Eloquent\Model
$credentials mixed (email, username, password, role)
Résultat Illuminate\Database\Eloquent\Model

getAll() public méthode

Get all user data.
public getAll ( ) : Illuminate\Database\Eloquent\Collection
Résultat Illuminate\Database\Eloquent\Collection | Illuminate\Database\Eloquent\Builder

getByEmail() public méthode

Get a user by email.
public getByEmail ( string $email ) : Illuminate\Database\Eloquent\Model
$email string
Résultat Illuminate\Database\Eloquent\Model

getById() public méthode

Get a user by user id.
public getById ( integer $id ) : Illuminate\Database\Eloquent\Model
$id integer
Résultat Illuminate\Database\Eloquent\Model

getByUsername() public méthode

Get a user by username.
public getByUsername ( string $username ) : Illuminate\Database\Eloquent\Model
$username string
Résultat Illuminate\Database\Eloquent\Model

getLikeUsername() public méthode

Get users by username like search.
public getLikeUsername ( string $username ) : Illuminate\Database\Eloquent\Model
$username string
Résultat Illuminate\Database\Eloquent\Model

getOwners() public méthode

Get users which role is owner.
public getOwners ( ) : Illuminate\Database\Eloquent\Model
Résultat Illuminate\Database\Eloquent\Model

getUsersToArray() public méthode

get users array
public getUsersToArray ( $users ) : array
Résultat array

updateUser() public méthode

Update a user information(username, email, role).
public updateUser ( integer $id, string $username, string $email, $role ) : Illuminate\Database\Eloquent\Model
$id integer
$username string
$email string
Résultat Illuminate\Database\Eloquent\Model

Property Details

$user protected_oe property

protected $user