Exemplo n.º 1
0
 /**
  * Create autodiscovery structure.
  */
 public function __construct(Connection $connection)
 {
     $this->connection = $connection;
     $this->cache = $this->connection->getCache()->derive('DiscoveredReflection');
     if ($this->cache) {
         $this->structure = $this->loadedStructure = $this->cache->load('structure') ?: array();
     }
     if (empty($this->structure)) {
         $this->reloadAllForeignKeys();
     }
 }