public function __get($name) { if (isset($this->computed[$name])) { return $this->computed[$name]; } if ('response' == $name) { $response = Yare::response(); $response->data($this); return $this->response = $response; } if (method_exists('Yare\\Yare', $name)) { return Yare::$name(); } if (method_exists($this, $name) && !in_array($name, static::$actions)) { return $this->computed[$name] = $this->{$name}(); } if ($value = $this->data[$name]) { return $value; } return $this->{$name} = ''; }