final public function fetchTableDef(string $table) {
        $tableKey = strtolower($table);

        // First check the table cache.
        if (isset($this->tables[$tableKey])) {
            $tableDef = $this->tables[$tableKey];

            if (isset($tableDef['columns'], $tableDef['indexes'])) {
                return $tableDef;
            }
        } elseif ($this->tableNames !== null && !isset($this->tableNames[$tableKey])) {
            return null;
        }

        $tableDef = $this->fetchTableDefDb($table);
        if ($tableDef !== null) {
            $this->fixIndexes($tableDef['name'], $tableDef);
            $this->tables[$tableKey] = $tableDef;
        }

        return $tableDef;
    }
final public function fetchTableDef(string $table) {
        $tableKey = strtolower($table);

        // First check the table cache.
        if (isset($this->tables[$tableKey])) {
            $tableDef = $this->tables[$tableKey];

            if (isset($tableDef['columns'], $tableDef['indexes'])) {
                return $tableDef;
            }
        } elseif ($this->tableNames !== null && !isset($this->tableNames[$tableKey])) {
            return null;
        }

        $tableDef = $this->fetchTableDefDb($table);
        if ($tableDef !== null) {
            $this->fixIndexes($tableDef['name'], $tableDef);
            $this->tables[$tableKey] = $tableDef;
        }

        return $tableDef;
    }
final public function fetchTableDef ( string $ table ) { $ tableKey = strtolower ( $ table ) ; // First check the table cache. if ( isset ( $ this -> tables [ $ tableKey ] ) ) { $ tableDef = $ this -> tables [ $ tableKey ] ; if ( isset ( $ tableDef [ 'columns' ] , $ tableDef [ 'indexes' ] ) ) { return $ tableDef ; } } elseif ( $ this -> tableNames !== null && ! isset ( $ this -> tableNames [ $ tableKey ] ) ) { return null ; } $ tableDef = $ this -> fetchTableDefDb ( $ table ) ; if ( $ tableDef !== null ) { $ this -> fixIndexes ( $ tableDef [ 'name' ] , $ tableDef ) ; $ this -> tables [ $ tableKey ] = $ tableDef ; } return $ tableDef ; }
Get a table definition.

@param string $table The name of the table.
@return array|null Returns the table definition or null if the table does not exist.
Get a table definition .