Ignore:
Timestamp:
2015-10-10T15:47:41+02:00 (9 years ago)
Author:
Don-vip
Message:

sonar - squid:S1149 - Synchronized classes Vector, Hashtable, Stack and StringBuffer should not be used

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/APIDataSet.java

    r8836 r8851  
    22package org.openstreetmap.josm.data;
    33
     4import java.util.ArrayDeque;
    45import java.util.ArrayList;
    56import java.util.Collection;
    67import java.util.Collections;
    78import java.util.Comparator;
     9import java.util.Deque;
    810import java.util.HashMap;
    911import java.util.HashSet;
     
    1214import java.util.Map;
    1315import java.util.Set;
    14 import java.util.Stack;
    1516
    1617import org.openstreetmap.josm.actions.upload.CyclicUploadDependencyException;
     
    309310        }
    310311
    311         protected void visit(Stack<Relation> path, Relation current) throws CyclicUploadDependencyException {
     312        protected void visit(Deque<Relation> path, Relation current) throws CyclicUploadDependencyException {
    312313            if (path.contains(current)) {
    313314                path.push(current);
     
    328329            visited = new HashSet<>();
    329330            uploadOrder = new LinkedList<>();
    330             Stack<Relation> path = new Stack<>();
     331            Deque<Relation> path = new ArrayDeque<>();
    331332            for (Relation relation: relations) {
    332333                visit(path, relation);
Note: See TracChangeset for help on using the changeset viewer.