Completed
Push — work-fleets ( 73ed38...ce5b3a )
by SuperNova.WS
05:53
created

ContainerPlus::__get()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
cc 1
eloc 2
nc 1
nop 1
dl 0
loc 3
rs 10
c 1
b 0
f 1
1
<?php
2
3
namespace Pimple;
4
5
/**
6
 * Class ContainerPlus
7
 *
8
 * Extends original container to allow access to properties and function to document them
9
 *
10
 * @package Pimple
11
 */
12
class ContainerPlus extends Container {
13
14
  public function __set($name, $value) {
15
    $this->offsetSet($name, $value);
16
  }
17
18
  public function __get($name) {
19
    return $this->offsetGet($name);
20
  }
21
22
  public function __isset($name) {
23
    return $this->offsetExists($name);
24
  }
25
26
  public function __unset($name) {
27
    $this->offsetUnset($name);
28
  }
29
30
  public function __call($name, $arguments) {
31
    return call_user_func_array($this->$name, $arguments);
32
  }
33
34
}
35