/** * Get a table instance * @param tableId Id of the table * @return table instance */ public Table getTable(String tableId) { Preconditions.checkState(initialized, "TableManager has not been initialized."); TableCtx ctx = tableContexts.get(tableId); Preconditions.checkNotNull(ctx, "Unknown tableId " + tableId); if (ctx.table == null) { ctx.table = ctx.tableProvider.getTable(); } return ctx.table; } }
/** * Get a table instance * @param tableId Id of the table * @return table instance */ public Table getTable(String tableId) { Preconditions.checkState(initialized, "TableManager has not been initialized."); TableCtx ctx = tableContexts.get(tableId); Preconditions.checkNotNull(ctx, "Unknown tableId " + tableId); if (ctx.table == null) { ctx.table = ctx.tableProvider.getTable(); } return ctx.table; } }
/** * Get a table instance * @param tableId Id of the table * @return table instance */ public Table getTable(String tableId) { Preconditions.checkState(initialized, "TableManager has not been initialized."); TableCtx ctx = tableContexts.get(tableId); Preconditions.checkNotNull(ctx, "Unknown tableId " + tableId); if (ctx.table == null) { ctx.table = ctx.tableProvider.getTable(); } return ctx.table; } }
/** * Get a table instance * @param tableId Id of the table * @return table instance */ public Table getTable(String tableId) { Preconditions.checkState(initialized, "TableManager has not been initialized."); TableCtx ctx = tableContexts.get(tableId); Preconditions.checkNotNull(ctx, "Unknown tableId " + tableId); if (ctx.table == null) { ctx.table = ctx.tableProvider.getTable(); } return ctx.table; } }