summaryrefslogtreecommitdiff
path: root/core/classes/authentication/Core/UserManagerInterface.php
blob: 4702992bd01d986fd54e4cbc385769ae206a21c6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<?php
/** Interface UserManagerInterface
 * 
 * @package DevCoder\Authentication\Core
 * 
 */
// namespace DevCoder\Authentication\Core;

// use DevCoder\Authentication\Token\UserTokenInterface;
// use DevCoder\Authentication\UserInterface;

interface UserManagerInterface
{
    public function getUserToken(): ?UserTokenInterface;

    public function hasUserToken(): bool;

    public function createUserToken(UserInterface $user): UserTokenInterface;

    public function logout(): void;

    public function cryptPassword(string $plainPassword): string;

    public function isPasswordValid(UserInterface $user, string $plainPassword): bool;
}