class BlockListAsLongs implements Iterable<BlockReportReplica> {

  public static BlockListAsLongs encode(
      final Collection<? extends Replica> replicas) {
    BlockListAsLongs.Builder builder = builder();
    for (Replica replica : replicas) {
      builder.add(replica);
    }
    return builder.build();
  }

}