import java.util.*; /** * This class manages one or more symbol tables for a compiler. * Tables are indexed from 0. * * @author Hyung-Joon Kim */ public class SymbolTable { private HashMap[] tables; /** * Construct a new SymbolTable manager with one table. */ public SymbolTable() { this(1); } /** * Construct a new SymbolTable manager with n tables. * @param n number of distinct tables to manage. */ public SymbolTable(int n) { tables = new HashMap[n]; for (int i=0; i