TableMetadataManager { public List<TableDesc> listAllTables(String prj) { try (AutoLock lock = srcTableMapLock.lockForWrite()) { return Lists.newArrayList(getAllTablesMap(prj).values()); } } private  TableMetadataManager(KylinConfig cfg); static TableMetadataManager getInstance(KylinConfig config); KylinConfig getConfig(); ResourceStore getStore(); void reloadSourceTableQuietly(String table, String project); List<TableDesc> listAllTables(String prj); Map<String, TableDesc> getAllTablesMap(String prj); TableDesc getTableDesc(String tableName, String prj); void saveSourceTable(TableDesc srcTable, String prj); void removeSourceTable(String tableIdentity, String prj); void resetProjectSpecificTableDesc(String prj); void reloadTableExtQuietly(String table, String project); TableExtDesc getTableExt(String tableName, String prj); TableExtDesc getTableExt(TableDesc t); void saveTableExt(TableExtDesc tableExt, String prj); void removeTableExt(String tableName, String prj); List<ExternalFilterDesc> listAllExternalFilters(); ExternalFilterDesc getExtFilterDesc(String filterTableName); void saveExternalFilter(ExternalFilterDesc desc); void removeExternalFilter(String name); static final Serializer<TableDesc> TABLE_SERIALIZER; }
@Test public void testListAllTables() throws Exception { List<TableDesc> tables = getInstance(getTestConfig()).listAllTables(null); Assert.assertNotNull(tables); Assert.assertTrue(tables.size() > 0); }