public String toString() {
if (deleted) return "ClusterSmall[" + getClusterId() + " - has been deleted or hasn't been created.]";
try {
- final TIntHashSet set = new TIntHashSet();
- TIntShortHashMap map = foreignTable.getResourceHashMap();
- map.forEachKey(new TIntProcedure() {
- @Override
- public boolean execute(int value) {
- set.add(value & 0xfffff000);
- return true;
- }
+ ForeignTableSmall ft = foreignTable;
+ if (ft == null)
+ return "ClusterSmall[" + getClusterId() + " - " + getNumberOfResources() + "]";
+ TIntShortHashMap map = ft.getResourceHashMap();
+ TIntHashSet set = new TIntHashSet();
+ map.forEachKey(value -> {
+ set.add(value & 0xfffff000);
+ return true;
});
return "ClusterSmall[" + getClusterId() + " - " + getNumberOfResources() + " - " + foreignTable.getResourceHashMap().size() + " - " + set.size() + "]";
} catch (Throwable e) {