Ignore:
Timestamp:
2014-10-18T23:07:52+02:00 (10 years ago)
Author:
donvip
Message:

[josm_plugins] fix Java 7 / unused code warnings

Location:
applications/editors/josm/plugins/tracer2/src/org/openstreetmap/josm/plugins/tracer2
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/tracer2/src/org/openstreetmap/josm/plugins/tracer2/ConnectWays.java

    r30047 r30737  
    146146     */
    147147    public static Command connect(Way newWay, LatLon pos, ServerParam param, boolean ctrl, boolean alt) {
    148         LinkedList<Command> cmds = new LinkedList<Command>();
    149         LinkedList<Command> cmds2 = new LinkedList<Command>();
     148        LinkedList<Command> cmds = new LinkedList<>();
     149        LinkedList<Command> cmds2 = new LinkedList<>();
    150150       
    151151        s_oParam = param;
     
    214214     */
    215215    public static List<Command> connectTo() {
    216         Map<Way, Way> modifiedWays = new HashMap<Way, Way>();
    217         LinkedList<Command> cmds = new LinkedList<Command>();
     216        Map<Way, Way> modifiedWays = new HashMap<>();
     217        LinkedList<Command> cmds = new LinkedList<>();
    218218        Way way = new Way(s_oWay);
    219219        for (int i = 0; i < way.getNodesCount() - 1; i++) {
     
    271271     */
    272272    private static List<Command> mergeNodes(Node n1, Node n2){
    273         List<Command> cmds = new LinkedList<Command>();
     273        List<Command> cmds = new LinkedList<>();
    274274        cmds.add(new MoveCommand(n2,
    275275                 (n1.getEastNorth().getX() - n2.getEastNorth().getX())/2,
  • applications/editors/josm/plugins/tracer2/src/org/openstreetmap/josm/plugins/tracer2/TagValues.java

    r30047 r30737  
    5353       
    5454        // get values
    55         List<String> tagValues = new ArrayList<String>();
     55        List<String> tagValues = new ArrayList<>();
    5656        List<AutoCompletionListItem> values = Main.main.getCurrentDataSet().getAutoCompletionManager().getValues(m_strTag);
    5757        for ( AutoCompletionListItem i : values ) {
     
    6565        } else {
    6666                String[] prefered = m_strPreferredValues.split(";");
    67                 tagValues = new ArrayList<String>();
     67                tagValues = new ArrayList<>();
    6868               
    6969                for (String str: prefered) {
  • applications/editors/josm/plugins/tracer2/src/org/openstreetmap/josm/plugins/tracer2/TracerAction.java

    r30077 r30737  
    8383       
    8484        Collection<OsmPrimitive> selection = getCurrentDataSet().getSelected();
    85         List<Command> commands = new ArrayList<Command>();
     85        List<Command> commands = new ArrayList<>();
    8686       
    8787        if ( checkActiveServerParam() == false ) return;
     
    281281   
    282282    private void traceSync(LatLon pos, ProgressMonitor progressMonitor) {
    283         Collection<Command> commands = new LinkedList<Command>();
     283        Collection<Command> commands = new LinkedList<>();
    284284       
    285285        progressMonitor.beginTask(null, 3);
     
    305305                    coordList = oTraceSimple.m_listLatLon;
    306306                } catch (Exception e) {
    307                 coordList = new ArrayList<LatLon>();
     307                coordList = new ArrayList<>();
    308308            }
    309309           
  • applications/editors/josm/plugins/tracer2/src/org/openstreetmap/josm/plugins/tracer2/TracerDebug.java

    r30047 r30737  
    6666                Collection<? extends OsmPrimitive> cpx = null;
    6767               
    68                 List<OsmPrimitive> lp1 = new LinkedList<OsmPrimitive>();
    69                 List<OsmPrimitive> lp2 = new LinkedList<OsmPrimitive>();
    70                 List<OsmPrimitive> lp3 = new LinkedList<OsmPrimitive>();
    71                 List<OsmPrimitive> lp = new LinkedList<OsmPrimitive>();
     68                List<OsmPrimitive> lp1 = new LinkedList<>();
     69                List<OsmPrimitive> lp2 = new LinkedList<>();
     70                List<OsmPrimitive> lp3 = new LinkedList<>();
     71                List<OsmPrimitive> lp = new LinkedList<>();
    7272               
    7373                cp1 = lp1;
  • applications/editors/josm/plugins/tracer2/src/org/openstreetmap/josm/plugins/tracer2/preferences/ServerParamList.java

    r30047 r30737  
    2929
    3030public class ServerParamList {
    31     ArrayList<ServerParam> m_listServerParam = new ArrayList<ServerParam>();
     31    ArrayList<ServerParam> m_listServerParam = new ArrayList<>();
    3232    ServerParam m_oActivParam = null;
    3333    String m_strFilename;
     
    107107   
    108108    public List<ServerParam> getEnableParamList() {
    109         List<ServerParam> listParam = new ArrayList<ServerParam>();
     109        List<ServerParam> listParam = new ArrayList<>();
    110110        for ( ServerParam param: m_listServerParam) {
    111111                if (param.isEnabled()) {
  • applications/editors/josm/plugins/tracer2/src/org/openstreetmap/josm/plugins/tracer2/server/GetTrace.java

    r30047 r30737  
    2828        private LatLon m_oLatLon;
    2929        private ServerParam m_oServerParam;
    30     public ArrayList<LatLon> m_listLatLon = new ArrayList<LatLon>();
     30    public ArrayList<LatLon> m_listLatLon = new ArrayList<>();
    3131   
    3232    /**
     
    7171            strResponse = strResponse.substring(1, strResponse.length()-1);
    7272           
    73             ArrayList<LatLon> nodelist = new ArrayList<LatLon>();
     73            ArrayList<LatLon> nodelist = new ArrayList<>();
    7474           
    7575            String[] astrPoints = strResponse.split("\\)\\(");
     
    8282            m_listLatLon = nodelist;
    8383        } catch (Exception e) {
    84                 m_listLatLon = new ArrayList<LatLon>();
     84                m_listLatLon = new ArrayList<>();
    8585        }
    8686    }
Note: See TracChangeset for help on using the changeset viewer.