Merge "Revert 'Use TreeMaps instead of Maps in a couple of places.'"

This commit is contained in:
Edwin Kempin
2013-02-28 06:34:09 +00:00
committed by Gerrit Code Review
2 changed files with 4 additions and 5 deletions

View File

@@ -89,7 +89,6 @@ import java.util.EnumSet;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.TreeMap;
public class ChangeJson {
private static final Logger log = LoggerFactory.getLogger(ChangeJson.class);
@@ -354,7 +353,7 @@ public class ChangeJson {
private Map<String, LabelInfo> initLabels(ChangeData cd, boolean standard)
throws OrmException {
TreeMap<String, LabelInfo> labels =
Map<String, LabelInfo> labels =
Maps.newTreeMap(LabelOrdering.create(approvalTypes));
for (SubmitRecord rec : submitRecords(cd)) {
if (rec.labels == null) {
@@ -472,7 +471,7 @@ public class ChangeJson {
boolean standard, boolean detailed) throws OrmException {
// We can only approximately reconstruct what the submit rule evaluator
// would have done. These should really come from a stored submit record.
TreeMap<String, LabelInfo> labels =
Map<String, LabelInfo> labels =
Maps.newTreeMap(LabelOrdering.create(approvalTypes));
for (PatchSetApproval psa : cd.currentApprovals(db)) {
ApprovalType type = approvalTypes.byId(psa.getCategoryId());

View File

@@ -38,7 +38,7 @@ import com.google.inject.Provider;
import java.util.Collection;
import java.util.List;
import java.util.TreeMap;
import java.util.Map;
public class ReviewerJson {
private final Provider<ReviewDb> db;
@@ -132,7 +132,7 @@ public class ReviewerJson {
public static class ReviewerInfo extends AccountInfo {
final String kind = "gerritcodereview#reviewer";
TreeMap<String, String> approvals;
Map<String, String> approvals;
protected ReviewerInfo(Account.Id id) {
super(id);