Documentation

Register

Use case for user registration.

Handles creating new user accounts.

Tags
since
3.0.0

Table of Contents

Properties

$passwordHasher  : PasswordHasher
Password hasher.
$repository  : UserRepositoryInterface
User repository.

Methods

__construct()  : mixed
Create a new Register use case.
execute()  : User
Execute the registration.

Properties

Methods

execute()

Execute the registration.

public execute(string $username, string $email, string $password) : User
Parameters
$username : string

Username

$email : string

Email address

$password : string

Plain-text password

Tags
throws
InvalidArgumentException

If validation fails

throws
RuntimeException

If registration fails

Return values
User

The created user


        
On this page

Search results