@Test public void getNumLocations() { mInfo.addWorker(1, "MEM"); mInfo.addWorker(2, "MEM"); mInfo.addWorker(3, "HDD"); assertEquals(3, mInfo.getNumLocations()); }
public int getNumLocations() { return mWorkerIdToAlias.size(); }
MasterBlockInfo { public int getNumLocations() { return mWorkerIdToAlias.size(); } }
MasterBlockInfo { public int getNumLocations() { return mWorkerIdToAlias.size(); } MasterBlockInfo(long blockId, long length); }
MasterBlockInfo { public int getNumLocations() { return mWorkerIdToAlias.size(); } MasterBlockInfo(long blockId, long length); long getLength(); synchronized void updateLength(long length); long getBlockId(); void addWorker(long workerId, String tierAlias); void removeWorker(long workerId); Set<Long> getWorkers(); int getNumLocations(); List<MasterBlockLocation> getBlockLocations(); boolean isInTier(String targetTierAlias); @Override String toString(); }
MasterBlockInfo { public int getNumLocations() { return mWorkerIdToAlias.size(); } MasterBlockInfo(long blockId, long length); long getLength(); synchronized void updateLength(long length); long getBlockId(); void addWorker(long workerId, String tierAlias); void removeWorker(long workerId); Set<Long> getWorkers(); int getNumLocations(); List<MasterBlockLocation> getBlockLocations(); boolean isInTier(String targetTierAlias); @Override String toString();  }