Completed
Push — master ( 1aea55...3a5ed6 )
by Ivannis Suárez
11:15
created

LogoutUserCommand::addValidationConstraints()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 3
rs 10
cc 1
eloc 1
nc 1
nop 1
1
<?php
2
/**
3
 * This file is part of the Cubiche package.
4
 *
5
 * Copyright (c) Cubiche
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 */
10
namespace Cubiche\Core\Bus\Tests\Fixtures\Command;
11
12
use Cubiche\Core\Bus\Command\CommandNamedInterface;
13
use Cubiche\Core\Bus\Command\CommandValidatableInterface;
14
use Cubiche\Core\Validator\Validator;
15
16
/**
17
 * LogoutUserCommand class.
18
 *
19
 * @author Ivannis Suárez Jerez <[email protected]>
20
 */
21
class LogoutUserCommand implements CommandNamedInterface, CommandValidatableInterface
22
{
23
    /**
24
     * @var string
25
     */
26
    protected $email;
27
28
    /**
29
     * LogoutUserCommand constructor.
30
     *
31
     * @param $email
32
     */
33
    public function __construct($email)
34
    {
35
        $this->setEmail($email);
36
    }
37
38
    /**
39
     * @return string
40
     */
41
    public function email()
42
    {
43
        return $this->email;
44
    }
45
46
    /**
47
     * @param string $email
48
     */
49
    public function setEmail($email)
50
    {
51
        $this->email = $email;
52
    }
53
54
    /**
55
     * @return bool
56
     */
57
    public function isLogin()
58
    {
59
        return false;
60
    }
61
62
    /**
63
     * {@inheritdoc}
64
     */
65
    public function name()
66
    {
67
        return 'logout_user';
68
    }
69
70
    /**
71
     * {@inheritdoc}
72
     */
73
    public function addValidationConstraints(Validator $validator)
74
    {
75
    }
76
}
77