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.

ArrayAccessTrait   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 39
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
wmc 4
lcom 0
cbo 0
dl 0
loc 39
rs 10
c 0
b 0
f 0

7 Methods

Rating   Name   Duplication   Size   Complexity  
A offsetExists() 0 4 1
A offsetGet() 0 4 1
A offsetSet() 0 4 1
A offsetUnset() 0 4 1
has() 0 1 ?
get() 0 1 ?
set() 0 1 ?
1
<?php
2
/**
3
 * Phossa Project
4
 *
5
 * PHP version 5.4
6
 *
7
 * @category  Library
8
 * @package   Phossa2\Di
9
 * @copyright Copyright (c) 2016 phossa.com
10
 * @license   http://mit-license.org/ MIT License
11
 * @link      http://www.phossa.com/
12
 */
13
/*# declare(strict_types=1); */
14
15
namespace Phossa2\Di\Traits;
16
17
/**
18
 * ArrayAccessTrait
19
 *
20
 * Array access for container
21
 *
22
 * @package Phossa2\Di
23
 * @author  Hong Zhang <[email protected]>
24
 * @see     \ArrayAccess
25
 * @version 2.0.0
26
 * @since   2.0.0 added
27
 */
28
trait ArrayAccessTrait
29
{
30
    public function offsetExists($offset)/*# : bool */
31
    {
32
        return $this->has($offset);
33
    }
34
35
    public function offsetGet($offset)
36
    {
37
        return $this->get($offset);
38
    }
39
40
    public function offsetSet($offset, $value)
41
    {
42
        $this->set($offset, $value);
43
    }
44
45
    public function offsetUnset($offset)
46
    {
47
        $this->offsetSet($offset, null);
48
    }
49
50
    // ContainerInterface related
51
52
    /**
53
     * @return bool
54
     */
55
    abstract public function has(/*# string */ $id)/*# : bool */;
56
    /**
57
     * @return mixed|null
58
     */
59
    abstract public function get(/*# string */ $id);
60
61
    // WritableInterface related
62
    /**
63
     * @return bool
64
     */
65
    abstract public function set(/*# string */ $id, $value)/*# : bool */;
66
}
67