Completed
Push — master ( 80a8a7...04a06d )
by Risan Bagja
11s
created

Credentials   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 44
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 3
lcom 0
cbo 0
dl 0
loc 44
ccs 8
cts 8
cp 1
rs 10
c 1
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getIdentifier() 0 4 1
A getSecret() 0 4 1
1
<?php
2
3
namespace Risan\OAuth1\Credentials;
4
5
abstract class Credentials implements CredentialsInterface
6
{
7
    /**
8
     * The credentials identifier.
9
     *
10
     * @var string
11
     */
12
    protected $identifier;
13
14
    /**
15
     * The credentials shared-secret.
16
     *
17
     * @var string
18
     */
19
    protected $secret;
20
21
    /**
22
     * Creaate the new Crendentials class instance.
23
     *
24
     * @param string $identifier
25
     * @param string $secret
26
     */
27 51
    public function __construct($identifier, $secret)
28
    {
29 51
        $this->identifier = $identifier;
30 51
        $this->secret = $secret;
31 51
    }
32
33
    /**
34
     * {@inheritDoc}
35
     */
36 8
    public function getIdentifier()
37
    {
38 8
        return $this->identifier;
39
    }
40
41
    /**
42
     * {@inheritDoc}
43
     */
44 12
    public function getSecret()
45
    {
46 12
        return $this->secret;
47
    }
48
}
49