GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — develop ( 50cef7...02ca20 )
by Rolf
01:54
created

StorageData::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 7
CRAP Score 1

Importance

Changes 5
Bugs 0 Features 0
Metric Value
c 5
b 0
f 0
dl 0
loc 8
ccs 7
cts 7
cp 1
rs 9.4285
cc 1
eloc 6
nc 1
nop 3
crap 1
1
<?php
2
namespace izzum\statemachine\persistence;
3
use izzum\statemachine\Identifier;
4
5
/**
6
 * Simple Helper class for storing data.
7
 * It does not have to be used by subclasses of Adapter, but it is used for
8
 * both the Session and Memory adapter classes.
9
 *
10
 * @author Rolf Vreijdenberger
11
 */
12
class StorageData {
13
    
14
    /**
15
     * the entity id
16
     * 
17
     * @var string
18
     */
19
    public $id;
20
    /**
21
     * the state the transition was made to (the current state)
22
     * 
23
     * @var string
24
     */
25
    public $state;
26
    
27
    /**
28
     * the statemachine name
29
     * 
30
     * @var string
31
     */
32
    public $machine;
33
    /**
34
     * the timestamp when the storagedata was created, ideally at storage time.
35
     * 
36
     * @var int
37
     */
38
    public $timestamp;
39
    
40
    public $message;
41
42
    /**
43
     *
44
     * @param Identifier $identifier          
45
     * @param string $state            
46
     */
47 18
    public function __construct(Identifier $identifier, $state, $message = null)
48
    {
49 18
        $this->id = $identifier->getEntityId();
50 18
        $this->machine = $identifier->getMachine();
51 18
        $this->state = $state;
52 18
        $this->timestamp = time();
53 18
        $this->message = $message;
54
    }
55
}