getMetadataCache(); if (!($this->references = $cache->get("$table#relations"))) { $table->getQueryExecutor()->execute( new \pq\Query\Writer(RELATION_SQL, array($table->getName())), function($result) use($table, $cache) { $this->references = $result->map(array(0,1), array(2,3,4), \pq\Result::FETCH_OBJECT); $cache->set("$table#relations", $this->references); } ); } } function __isset($r) { return isset($this->references->$r); } function __get($r) { return $this->references->$r; } function __set($r, $v) { $this->references->$r = $v; } function __unset($r){ unset($this->references->$r); } }