Completed
Pull Request — master (#9)
by Samuel
03:17
created

AbstractBehaviour   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 44
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 66.67%

Importance

Changes 0
Metric Value
wmc 6
c 0
b 0
f 0
lcom 0
cbo 0
dl 0
loc 44
ccs 8
cts 12
cp 0.6667
rs 10

6 Methods

Rating   Name   Duplication   Size   Complexity  
A beforeInsert() 0 3 1
A afterInsert() 0 3 1
A beforeUpdate() 0 3 1
A afterUpdate() 0 3 1
A beforeDelete() 0 3 1
A afterDelete() 0 3 1
1
<?php
2
3
namespace SimpleMapper\Behaviour;
4
5
use SimpleMapper\ActiveRow;
6
7
abstract class AbstractBehaviour implements Behaviour
8
{
9
    /**
10
     * @inheritdoc
11
     */
12
    public function beforeInsert(array $data): array
13
    {
14
    }
15
16
    /**
17
     * @inheritdoc
18
     */
19 2
    public function afterInsert(ActiveRow $record, array $data): void
20
    {
21 2
    }
22
23
    /**
24
     * @inheritdoc
25
     */
26
    public function beforeUpdate(ActiveRow $record, array $data): array
27
    {
28
    }
29
30
    /**
31
     * @inheritdoc
32
     */
33 2
    public function afterUpdate(ActiveRow $oldRecord, ActiveRow $newRecord, array $data): void
34
    {
35 2
    }
36
37
    /**
38
     * @inheritdoc
39
     */
40 2
    public function beforeDelete(ActiveRow $record, bool $soft): void
41
    {
42 2
    }
43
44
    /**
45
     * @inheritdoc
46
     */
47 2
    public function afterDelete(ActiveRow $record, bool $soft): void
48
    {
49 2
    }
50
}
51