code: void metaSave(PrintWriter out) {
      synchronized (pendingReplications) {
        out.println("Metasave: Blocks being replicated: " +
                    pendingReplications.size());
        Iterator<Map.Entry<BlockInfo, PendingBlockInfo>> iter = 
            pendingReplications.entrySet().iterator();
        while (iter.hasNext()) {
          Map.Entry<BlockInfo, PendingBlockInfo> entry = iter.next();
          PendingBlockInfo pendingBlock = entry.getValue();
          BlockInfo block = entry.getKey();
          out.println(block + 
                      " StartTime: " + new Time(pendingBlock.timeStamp) +
                      " NumReplicaInProgress: " + 
                      pendingBlock.numReplicasInProgress);
        }
      }
    }
docs: Iterate through all items and print them.