Identification   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Importance

Changes 0
Metric Value
dl 0
loc 17
rs 10
c 0
b 0
f 0
wmc 3
lcom 1
cbo 1

3 Methods

Rating   Name   Duplication   Size   Complexity  
A isIdentified() 0 4 1
A requiresWayf() 0 4 1
A getWayfUrl() 0 4 1
1
<?php
2
3
namespace LibLynx\Connect\Resource;
4
5
/**
6
 * Provides a simple wrapper around a LibLynx identification resource
7
 * @package LibLynx\Connect
8
 *
9
 * @property \stdClass $id
10
 * @property \stdClass $ip
11
 * @property \stdClass $url
12
 * @property \stdClass $user_agent
13
 * @property \stdClass $account
14
 * @property \stdClass $status
15
 */
16
class Identification extends AbstractResource
17
{
18
    public function isIdentified()
19
    {
20
        return $this->status == 'identified';
21
    }
22
23
    public function requiresWayf()
24
    {
25
        return $this->status == 'wayf';
26
    }
27
28
    public function getWayfUrl()
29
    {
30
        return $this->getLink('wayf');
31
    }
32
}
33