private function _add($type, $object) { if (!is_null($this->_schema) && $this->_db->getDriver() != 'sqlite') { $_schema = $this->_schema . '.'; } else { $_schema = null; } $sql = "SELECT * from {$_schema}{$object}"; $stmt = $this->_db->prepare($sql); $stmt->execute(); //$row = $stmt->fetch(); $columnCount = $stmt->columnCount(); $conf = array(); for ($i = 0; $i < $columnCount; $i++) { $meta = $stmt->getColumnMeta($i); $conf['columns'][$meta['name']] = $meta; } echo "[ok] {$type} - {$object}\n"; $this->_items[] = array('type' => $type, 'name' => $object, 'conf' => $conf); }