/** * Get the default name of the distinct map table. This is the same as calling * * <code> * getTableName(false, false, false, true); * </code> * * @return table name */ public String getMapTableName() { return getTableName(false, false, false, true); }
/** * Get the default index table name. This is the same as calling * * <code> * getTableName(false, false, false, false); * </code> * * @return table name */ public String getTableName() { return getTableName(false, false, false, false); }
/** * Get the default name of the distinct table. This is the same as calling * * <code> * getTableName(false, false, true, false); * </code> * * @return table name */ public String getDistinctTableName() { return getTableName(false, false, true, false); }
/** * Get the name of the table in the given circumstances. This is the same as calling * * <code> * getTableName(isCommunity, isCollection, false, false); * </code> * * @param isCommunity whether this is a community constrained index (view) * @param isCollection whether this is a collection constrained index (view) * @return the name of the table * @deprecated 1.5 */ public String getTableName(boolean isCommunity, boolean isCollection) { return getTableName(isCommunity, isCollection, false, false); }
/** * Get the name of the table in the given circumstances * * @param isCommunity whether this is a community constrained index (view) * @param isCollection whether this is a collection constrained index (view) * @param isDistinct whether this is a distinct table * @param isMap whether this is a distinct map table * @return the name of the table * @deprecated 1.5 */ public String getTableName(boolean isCommunity, boolean isCollection, boolean isDistinct, boolean isMap) { if (isDistinct || isMap) { return BrowseIndex.getTableName(number, isCommunity, isCollection, isDistinct, isMap); } return BrowseIndex.getTableName(tableBaseName, isCommunity, isCollection, isDistinct, isMap); }
/** * Get the table name for the given set of circumstances. * * This is the same as calling: * * <code> * getTableName(isCommunity, isCollection, isDistinct, false); * </code> * * @param isCommunity whether this is a community constrained index (view) * @param isCollection whether this is a collection constrained index (view) * @param isDistinct whether this is a distinct table * @return table name * @deprecated 1.5 */ public String getTableName(boolean isDistinct, boolean isCommunity, boolean isCollection) { return getTableName(isCommunity, isCollection, isDistinct, false); }
@Override public void setTable(String table) { if (table.equals(BrowseIndex.getWithdrawnBrowseIndex().getTableName())) { itemsWithdrawn = true; } else if (table.equals(BrowseIndex.getPrivateBrowseIndex().getTableName())) { itemsDiscoverable = false; } facetField = table; }
/** * @return array of tables * @throws BrowseException if browse error * @deprecated */ public static String[] tables() throws BrowseException { BrowseIndex[] bis = getBrowseIndices(); String[] returnTables = new String[bis.length]; for (int i = 0; i < bis.length; i++) { returnTables[i] = bis[i].getTableName(); } return returnTables; }
/** * Get the name of the table for the given set of circumstances * This is provided solely for cleaning the database, where you are * trying to create table names that may not be reflected in the current index * * @param number the index configuration number * @param isCommunity whether this is a community constrained index (view) * @param isCollection whether this is a collection constrained index (view) * @param isDistinct whether this is a distinct table * @param isMap whether this is a distinct map table * @return the name of the table * @deprecated 1.5 */ public static String getTableName(int number, boolean isCommunity, boolean isCollection, boolean isDistinct, boolean isMap) { return BrowseIndex.getTableName(makeTableBaseName(number), isCommunity, isCollection, isDistinct, isMap); }
/** * drop the tables and related database entries for the internal * 'item' tables * * @param connection Database Connection * @param bix BrowseIndex * @throws BrowseException */ private void dropItemTables(Connection connection, BrowseIndex bix) throws BrowseException { if (DatabaseUtils.tableExists(connection, bix.getTableName())) { String tableName = bix.getTableName(); String sequence = bix.getSequenceName(false, false); // Drop table dropTable(connection, tableName); // Drop sequence dropSequence(connection, sequence); // These views are no longer used, but as we are cleaning the database, // they may exist and need to be removed String colViewName = bix.getTableName(false, true, false, false); String comViewName = bix.getTableName(true, false, false, false); // Drop Collection View dropView(connection, colViewName); // Drop Community View dropView(connection, comViewName); } }
String tableName = BrowseIndex.getTableName(i, false, false, false, false); String distinctTableName = BrowseIndex.getTableName(i, false, false, true, false); String distinctMapName = BrowseIndex.getTableName(i, false, false, false, true); String sequence = BrowseIndex.getSequenceName(i, false, false); String mapSequence = BrowseIndex.getSequenceName(i, false, true); String colViewName = BrowseIndex.getTableName(i, false, true, false, false); String comViewName = BrowseIndex.getTableName(i, true, false, false, false); String distinctColViewName = BrowseIndex.getTableName(i, false, true, false, true); String distinctComViewName = BrowseIndex.getTableName(i, true, false, false, true);
String tableName = browseIndex.getTableName();
+ bi.getTableName());
dao.setTable(browseIndex.getTableName());
try { dao.setTable(browseIndex.getTableName());