// Inherit interface docs. @Override public TableInfo openTable(String tableName) throws IOException { TableInfo tableInfo; // If the table is already open, just return the cached information. tableInfo = openTables.get(tableName); if (tableInfo != null) return tableInfo; // Open the data file for the table; read out its type and page-size. String tblFileName = getTableFileName(tableName); TupleFile tupleFile = storageManager.openTupleFile(tblFileName); tableInfo = new TableInfo(tableName, tupleFile); // Cache this table since it's now considered "open". openTables.put(tableName, tableInfo); return tableInfo; }