| 1 | <?php namespace Anomaly\UsersModule\User; |
||
| 10 | class UserActivator |
||
| 11 | { |
||
| 12 | use DispatchesJobs; |
||
| 13 | |||
| 14 | /** |
||
| 15 | * Start a user activation process. |
||
| 16 | * |
||
| 17 | * @param UserInterface $user |
||
| 18 | * @return bool |
||
| 19 | */ |
||
| 20 | public function start(UserInterface $user) |
||
| 24 | |||
| 25 | /** |
||
| 26 | * Activate a user by code. |
||
| 27 | * |
||
| 28 | * @param UserInterface $user |
||
| 29 | * @param $code |
||
| 30 | * @return bool |
||
| 31 | */ |
||
| 32 | public function activate(UserInterface $user, $code) |
||
| 36 | |||
| 37 | /** |
||
| 38 | * Activate a user by force. |
||
| 39 | * |
||
| 40 | * @param UserInterface $user |
||
| 41 | * @return bool |
||
| 42 | */ |
||
| 43 | public function force(UserInterface $user) |
||
| 47 | |||
| 48 | /** |
||
| 49 | * Send an activation email. |
||
| 50 | * |
||
| 51 | * @param UserInterface $user |
||
| 52 | * @param string $redirect |
||
| 53 | * @return bool |
||
| 54 | */ |
||
| 55 | public function send(UserInterface $user, $redirect = '/') |
||
| 59 | } |
||
| 60 |