aboutsummaryrefslogtreecommitdiff
path: root/test/Foo.php
blob: 4b6148b66d46b0d5122f3083edd85873446af60b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
<?php
/**
 * User: Victor Häggqvist
 * Date: 3/4/15
 * Time: 12:58 PM
 */

class Foo {
  public $name;
  private $attrs = array();

  public function __isset($name) {
    return isset($this->attrs[$name]);
  }

  public function __get($name) {
    return $this->attrs[$name];
  }

  public function __set($name, $value) {
    $this->attrs[$name] = $value;
  }
}