AuthEvent   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 45
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 8
c 1
b 0
f 0
dl 0
loc 45
ccs 4
cts 4
cp 1
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A setForm() 0 3 1
A getForm() 0 3 1
1
<?php
2
3
namespace terabytesoft\events\user;
4
5
use yii\base\Event;
6
7
/**
8
 * Class AuthEvent
9
 *
10
 * Auth events applications
11
 **/
12
class AuthEvent extends Event
13
{
14
    /**
15
     * event is triggered before authenticating user via social network
16
     * triggered with \terabytesoft\events\user\AuthEvent
17
     **/
18
    const BEFORE_AUTHENTICATE = '\terabytesoft\events\user\AuthEvent::BEFORE_AUTHENTICATE';
19
20
    /**
21
     * event is triggered after authenticating user via social network
22
     * triggered with \terabytesoft\events\user\AuthEvent
23
     **/
24
    const AFTER_AUTHENTICATE = '\terabytesoft\events\user\AuthEvent::AFTER_AUTHENTICATE';
25
26
    /**
27
     * event is triggered before connecting social network account to user
28
     * triggered with \terabytesoft\events\user\AuthEvent
29
     **/
30
    const BEFORE_CONNECT = '\terabytesoft\events\user\AuthEvent::BEFORE_CONNECT';
31
32
    /**
33
     * event is triggered before connecting social network account to user
34
     * triggered with \terabytesoft\events\user\AuthEvent.
35
     **/
36
    const AFTER_CONNECT = '\terabytesoft\events\user\AuthEvent::AFTER_CONNECT';
37
38
    /**
39
     * @var object $form
40
     */
41
    private $form;
42
43
    /**
44
     * getForm
45
     */
46 2
    public function getForm(): object
47
    {
48 2
        return $this->form;
49
    }
50
51
    /**
52
     * setForm
53
     */
54 2
    public function setForm(object $form): void
55
    {
56 2
        $this->form = $form;
57 2
    }
58
}
59