Index: /applications/editors/josm/plugins/routing/.checkstyle
===================================================================
--- /applications/editors/josm/plugins/routing/.checkstyle	(revision 32768)
+++ /applications/editors/josm/plugins/routing/.checkstyle	(revision 32768)
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<fileset-config file-format-version="1.2.0" simple-config="true" sync-formatter="false">
+  <local-check-config name="JOSM" location="/JOSM/tools/checkstyle/josm_checks.xml" type="project" description="">
+    <additional-data name="protect-config-file" value="false"/>
+  </local-check-config>
+  <fileset name="all" enabled="true" check-config-name="JOSM" local="true">
+    <file-match-pattern match-pattern="." include-pattern="true"/>
+  </fileset>
+  <filter name="DerivedFiles" enabled="true"/>
+  <filter name="FilesFromPackage" enabled="true">
+    <filter-data value="data"/>
+    <filter-data value="images"/>
+    <filter-data value="styles"/>
+    <filter-data value="resources"/>
+    <filter-data value="scripts"/>
+  </filter>
+</fileset-config>
Index: /applications/editors/josm/plugins/routing/.project
===================================================================
--- /applications/editors/josm/plugins/routing/.project	(revision 32767)
+++ /applications/editors/josm/plugins/routing/.project	(revision 32768)
@@ -16,7 +16,13 @@
 			</arguments>
 		</buildCommand>
+		<buildCommand>
+			<name>net.sf.eclipsecs.core.CheckstyleBuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
 	</buildSpec>
 	<natures>
 		<nature>org.eclipse.jdt.core.javanature</nature>
+		<nature>net.sf.eclipsecs.core.CheckstyleNature</nature>
 	</natures>
 </projectDescription>
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/EdgeIterator.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/EdgeIterator.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/EdgeIterator.java	(revision 32768)
@@ -1,9 +1,10 @@
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.jrt.core;
 
 public interface EdgeIterator {
 
-    public boolean hasNext();
+    boolean hasNext();
 
-    public RoutingEdge next();
+    RoutingEdge next();
 
 }
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingEdge.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingEdge.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingEdge.java	(revision 32768)
@@ -1,2 +1,3 @@
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.jrt.core;
 
@@ -5,23 +6,23 @@
 public interface RoutingEdge {
 
-      public LatLon fromLatLon();
+    LatLon fromLatLon();
 
-      public LatLon toLatLon();
+    LatLon toLatLon();
 
-      public Object fromV();
+    Object fromV();
 
-      public Object toV();
+    Object toV();
 
-      public double getLength();
+    double getLength();
 
-      public void setLength(double length);
+    void setLength(double length);
 
-      public double getSpeed();
+    double getSpeed();
 
-      public void setSpeed(double speed);
+    void setSpeed(double speed);
 
-      public boolean isOneway();
+    boolean isOneway();
 
-      public void setOneway(boolean isOneway);
+    void setOneway(boolean isOneway);
 
 }
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingGraph.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingGraph.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingGraph.java	(revision 32768)
@@ -1,29 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.jrt.core;
 
@@ -68,10 +42,13 @@
     public enum Algorithm {
         ROUTING_ALG_DIJKSTRA, ROUTING_ALG_BELLMANFORD
-    };
+    }
 
     /**
      * Search criteria for the route.
      */
-    public enum RouteType {FASTEST,SHORTEST};
+    public enum RouteType {
+        FASTEST,
+        SHORTEST
+    }
 
     /**
@@ -91,8 +68,8 @@
 
     private static Collection<String> excludedHighwayValues = Arrays.asList(new String[]{
-        "bus_stop", "traffic_signals", "street_lamp", "stop", "construction", 
-        "platform", "give_way", "proposed", "milestone", "speed_camera", "abandoned"
+            "bus_stop", "traffic_signals", "street_lamp", "stop", "construction",
+            "platform", "give_way", "proposed", "milestone", "speed_camera", "abandoned"
     });
-    
+
     /**
      * Graph state
@@ -108,5 +85,5 @@
     //  private WeightedMultigraph<Node, OsmEdge> graph;
     private Graph<Node, OsmEdge> graph;
-    private RoutingGraphDelegator rgDelegator=null;
+    private RoutingGraphDelegator rgDelegator = null;
 
 
@@ -114,21 +91,19 @@
      * Graph getter
      */
-    public Graph<Node, OsmEdge> getGraph(){
+    public Graph<Node, OsmEdge> getGraph() {
         return graph;
-
-    }
-
-
-    private void addEdgeBidirectional( Way way, Node from, Node to){
-        addEdge(way,from,to);
-        addEdge(way,to,from);
-    }
-
-    private void addEdgeReverseOneway( Way way, Node from, Node to){
-        addEdge(way,to,from);
-    }
-
-    private void addEdgeNormalOneway( Way way, Node from, Node to){
-        addEdge(way,from,to);
+    }
+
+    private void addEdgeBidirectional(Way way, Node from, Node to) {
+        addEdge(way, from, to);
+        addEdge(way, to, from);
+    }
+
+    private void addEdgeReverseOneway(Way way, Node from, Node to) {
+        addEdge(way, to, from);
+    }
+
+    private void addEdgeNormalOneway(Way way, Node from, Node to) {
+        addEdge(way, from, to);
     }
 
@@ -136,5 +111,5 @@
      * Speeds
      */
-    private Map<String,Double> waySpeeds;
+    private Map<String, Double> waySpeeds;
 
     /**
@@ -145,6 +120,6 @@
         this.graph = null;
         this.data = data;
-        routeType=RouteType.SHORTEST;
-        routingProfile=new RoutingProfile("default");
+        routeType = RouteType.SHORTEST;
+        routingProfile = new RoutingProfile("default");
         routingProfile.setOnewayUse(true); // Don't ignore oneways by default
         this.setWaySpeeds(routingProfile.getWaySpeeds());
@@ -154,6 +129,4 @@
     /**
      * Create OSM graph for routing
-     *
-     * @return
      */
     public void createGraph() {
@@ -161,5 +134,5 @@
         logger.debug("Creating Graph...");
         graph = new DirectedWeightedMultigraph<>(OsmEdge.class);
-        rgDelegator=new RoutingGraphDelegator(graph);
+        rgDelegator = new RoutingGraphDelegator(graph);
         rgDelegator.setRouteType(this.routeType);
         // iterate all ways and segments for all nodes:
@@ -178,18 +151,18 @@
             /*
              * Assume node is A B C D E. The procedure should be
-             * 
+             *
              *  case 1 - bidirectional ways:
              *  1) Add vertex A B C D E
              *  2) Link A<->B, B<->C, C<->D, D<->E as Edges
-             * 
+             *
              *  case 2 - oneway reverse:
              *  1) Add vertex A B C D E
              *  2) Link B->A,C->B,D->C,E->D as Edges. result: A<-B<-C<-D<-E
-             * 
+             *
              *  case 3 - oneway normal:
              *  1) Add vertex A B C D E
              *  2) Link A->B, B->C, C->D, D->E as Edges. result: A->B->C->D->E
-             * 
-             * 
+             *
+             *
              */
 
@@ -244,9 +217,6 @@
     /**
      * Compute weight and add edge to the graph
-     * @param way
-     * @param from
-     * @param to
-     */
-    private void addEdge(Way way,Node from, Node to) {
+     */
+    private void addEdge(Way way, Node from, Node to) {
         LatLon fromLL = from.getCoor();
         LatLon toLL = from.getCoor();
@@ -263,7 +233,7 @@
         setWeight(edge, length);
         logger.debug("edge for way " + way.getId()
-                + "(from node " + from.getId() + " to node "
-                + to.getId() + ") has weight: " + weight);
-        ((DirectedWeightedMultigraph<Node,OsmEdge>)graph).setEdgeWeight(edge, weight);
+        + "(from node " + from.getId() + " to node "
+        + to.getId() + ") has weight: " + weight);
+        ((DirectedWeightedMultigraph<Node, OsmEdge>) graph).setEdgeWeight(edge, weight);
     }
 
@@ -275,5 +245,4 @@
      * @param way
      *            the way.
-     * @return
      */
     private void setWeight(OsmEdge osmedge, double length) {
@@ -292,5 +261,4 @@
      * @param way
      *            the way.
-     * @return
      */
     private double getWeight(Way way, double length) {
@@ -302,10 +270,10 @@
             // Same speed for all types of ways
             if (this.waySpeeds.containsKey("residential"))
-                speed=this.waySpeeds.get("residential");
+                speed = this.waySpeeds.get("residential");
             break;
         case FASTEST:
             // Each type of way may have a different speed
             if (this.waySpeeds.containsKey(way.get("highway")))
-                speed=this.waySpeeds.get(way.get("highway"));
+                speed = this.waySpeeds.get(way.get("highway"));
             logger.debug("Speed="+speed);
             break;
@@ -327,5 +295,5 @@
         //if (!way.isTagged())            <---not needed me thinks
         //    return false;
-        
+
         String highway = way.get("highway");
 
@@ -348,7 +316,7 @@
     public List<OsmEdge> applyAlgorithm(List<Node> nodes, Algorithm algorithm) {
         List<OsmEdge> path = new ArrayList<>();
-        Graph<Node,OsmEdge> g;
+        Graph<Node, OsmEdge> g;
         double totalWeight = 0;
-        RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+        RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
         RoutingModel routingModel = layer.getRoutingModel();
 
@@ -405,7 +373,7 @@
      * @return the number of vertices.
      */
-    public int getVertexCount(){
-        int value=0;
-        if (graph!=null) value=graph.vertexSet().size();
+    public int getVertexCount() {
+        int value = 0;
+        if (graph != null) value = graph.vertexSet().size();
         return value;
     }
@@ -415,7 +383,7 @@
      * @return the number of edges.
      */
-    public int getEdgeCount(){
-        int value=0;
-        if (graph!=null) value=graph.edgeSet().size();
+    public int getEdgeCount() {
+        int value = 0;
+        if (graph != null) value = graph.edgeSet().size();
         return value;
     }
@@ -445,5 +413,5 @@
 
     public void resetGraph() {
-        graph=null;
+        graph = null;
     }
 
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingGraphDelegator.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingGraphDelegator.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingGraphDelegator.java	(revision 32768)
@@ -1,5 +1,3 @@
-/**
- *
- */
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.jrt.core;
 
@@ -9,5 +7,4 @@
 import org.openstreetmap.josm.data.osm.Node;
 
-import com.innovant.josm.jrt.core.RoutingGraphDelegator;
 import com.innovant.josm.jrt.core.RoutingGraph.RouteType;
 import com.innovant.josm.jrt.osm.OsmEdge;
@@ -33,5 +30,4 @@
     }
 
-
     public RouteType getRouteType() {
         return routeType;
@@ -42,5 +38,4 @@
     }
 
-
     /**
      *
@@ -50,8 +45,8 @@
     @Override
     public double getEdgeWeight(OsmEdge edge) {
-        double weight=Double.MAX_VALUE;
+        double weight = Double.MAX_VALUE;
 
-        if (routeType==RouteType.SHORTEST) weight=edge.getLength();
-        if (routeType==RouteType.FASTEST) weight=edge.getLength() / edge.getSpeed();
+        if (routeType == RouteType.SHORTEST) weight = edge.getLength();
+        if (routeType == RouteType.FASTEST) weight = edge.getLength() / edge.getSpeed();
         // Return the time spent to traverse the way
         return weight;
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingProfile.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingProfile.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/core/RoutingProfile.java	(revision 32768)
@@ -1,2 +1,3 @@
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.jrt.core;
 
@@ -57,5 +58,5 @@
      * A speed of zero means that this type of way cannot be traversed.
      */
-    private Map<String,Double> waySpeeds;
+    private Map<String, Double> waySpeeds;
 
 
@@ -64,5 +65,5 @@
      * Holds permission of use for each type of transport mode, using the mode as key.
      */
-    private Map<String,Boolean> allowedModes;
+    private Map<String, Boolean> allowedModes;
 
     /**
@@ -75,11 +76,12 @@
         logger.debug("Init RoutingProfile with name: "+name);
         this.name = name;
-        waySpeeds=new HashMap<>();
-        Map<String,String> prefs=Main.pref.getAllPrefix("routing.profile."+name+".speed");
-        for(String key:prefs.keySet()){
+        waySpeeds = new HashMap<>();
+        Map<String, String> prefs = Main.pref.getAllPrefix("routing.profile."+name+".speed");
+        for (String key:prefs.keySet()) {
             waySpeeds.put((key.split("\\.")[4]), Double.valueOf(prefs.get(key)));
         }
-        for (String key:waySpeeds.keySet())
+        for (String key:waySpeeds.keySet()) {
             logger.debug(key+ "-- speed: "+waySpeeds.get(key));
+        }
         logger.debug("End init RoutingProfile with name: "+name);
     }
@@ -147,6 +149,6 @@
     }
 
-    public double getSpeed(String key){
-        if(!waySpeeds.containsKey(key)) return 0.0;
+    public double getSpeed(String key) {
+        if (!waySpeeds.containsKey(key)) return 0.0;
         return waySpeeds.get(key);
     }
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/gtfs/GTFSTransportModes.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/gtfs/GTFSTransportModes.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/gtfs/GTFSTransportModes.java	(revision 32768)
@@ -1,2 +1,3 @@
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.jrt.gtfs;
 
@@ -7,5 +8,9 @@
  * Routing Profile keys should be Strings
  */
-public class GTFSTransportModes {
+public final class GTFSTransportModes {
+
+    private GTFSTransportModes() {
+
+    }
 
     /**
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/osm/OsmEdge.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/osm/OsmEdge.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/osm/OsmEdge.java	(revision 32768)
@@ -1,28 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.jrt.osm;
 
@@ -37,32 +12,29 @@
  */
 public class OsmEdge extends DefaultWeightedEdge {
- /**
-  * Serial
-  */
-  private static final long serialVersionUID = 1L;
-  /**
-   * Way associated
-   */
-  private Way way;
-  /**
-   * Nodes in the edge
-   */
-  private Node from, to;
-  /**
-   * Length edge
-   */
-  private double length;
-  /**
-   * Speed edge.
-   */
-  private double speed;
+    /**
+     * Serial
+     */
+    private static final long serialVersionUID = 1L;
+    /**
+     * Way associated
+     */
+    private Way way;
+    /**
+     * Nodes in the edge
+     */
+    private Node from, to;
+    /**
+     * Length edge
+     */
+    private double length;
+    /**
+     * Speed edge.
+     */
+    private double speed;
 
-
-/**
-   * Constructor
-   * @param way
-   * @param length
-   */
-  public OsmEdge(Way way, Node from, Node to) {
+    /**
+     * Constructor
+     */
+    public OsmEdge(Way way, Node from, Node to) {
         super();
         this.way = way;
@@ -70,39 +42,39 @@
         this.to = to;
         this.length = from.getCoor().greatCircleDistance(to.getCoor());
-      }
+    }
 
-  /**
-   * @return the way
-   */
-  public Way getWay() {
-      return this.way;
-  }
+    /**
+     * @return the way
+     */
+    public Way getWay() {
+        return this.way;
+    }
 
-  public EastNorth fromEastNorth() {
-      return this.from.getEastNorth();
-  }
+    public EastNorth fromEastNorth() {
+        return this.from.getEastNorth();
+    }
 
-  public EastNorth toEastNorth() {
-      return this.to.getEastNorth();
-  }
+    public EastNorth toEastNorth() {
+        return this.to.getEastNorth();
+    }
 
-  /**
-   * Returns length of segment in meters
-   * @return length of segment in meters.
-   */
-  public double getLength() {
-    return length;
-  }
+    /**
+     * Returns length of segment in meters
+     * @return length of segment in meters.
+     */
+    public double getLength() {
+        return length;
+    }
 
-  public void setLength(double length) {
-    this.length = length;
+    public void setLength(double length) {
+        this.length = length;
+    }
+
+    public double getSpeed() {
+        return speed;
+    }
+
+    public void setSpeed(double speed) {
+        this.speed = speed;
+    }
 }
-
-public double getSpeed() {
-        return speed;
-  }
-
-  public void setSpeed(double speed) {
-        this.speed = speed;
-  }
-}
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/osm/OsmWayTypes.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/osm/OsmWayTypes.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/jrt/osm/OsmWayTypes.java	(revision 32768)
@@ -1,30 +1,3 @@
-/*
- *
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.jrt.osm;
 
@@ -34,32 +7,31 @@
  */
 public enum OsmWayTypes {
-    MOTORWAY ("motorway",120),
-    MOTORWAY_LINK ("motorway_link",120),
-    TRUNK ("trunk",120),
-    TRUNK_LINK ("trunk_link",120),
-    PRIMARY  ("primary",100),
-    PRIMARY_LINK ("primary_link",100),
-    SECONDARY ("secondary",90),
-    TERTIARY ("tertiary",90),
-    UNCLASSIFIED ("unclassified",50),
-    ROAD ("road",100),
-    RESIDENTIAL ("residential",50),
-    LIVING_STREET ("living_street",30),
-    SERVICE ("service",30),
-    TRACK ("track",50),
-    PEDESTRIAN ("pedestrian",30),
-    BUS_GUIDEWAY ("bus_guideway",50),
-    PATH ("path",40),
-    CYCLEWAY ("cycleway",40),
-    FOOTWAY ("footway",20),
-    BRIDLEWAY ("bridleway",40),
-    BYWAY ("byway",50),
-    STEPS ("steps",10);
+    MOTORWAY("motorway", 120),
+    MOTORWAY_LINK("motorway_link", 120),
+    TRUNK("trunk", 120),
+    TRUNK_LINK("trunk_link", 120),
+    PRIMARY("primary", 100),
+    PRIMARY_LINK("primary_link", 100),
+    SECONDARY("secondary", 90),
+    TERTIARY("tertiary", 90),
+    UNCLASSIFIED("unclassified", 50),
+    ROAD("road", 100),
+    RESIDENTIAL("residential", 50),
+    LIVING_STREET("living_street", 30),
+    SERVICE("service", 30),
+    TRACK("track", 50),
+    PEDESTRIAN("pedestrian", 30),
+    BUS_GUIDEWAY("bus_guideway", 50),
+    PATH("path", 40),
+    CYCLEWAY("cycleway", 40),
+    FOOTWAY("footway", 20),
+    BRIDLEWAY("bridleway", 40),
+    BYWAY("byway", 50),
+    STEPS("steps", 10);
 
     /**
      * Default Constructor
-     * @param tag
      */
-    OsmWayTypes(String tag,int speed) {
+    OsmWayTypes(String tag, int speed) {
         this.tag = tag;
         this.speed = speed;
@@ -72,8 +44,10 @@
     private final int speed;
 
-    /**
-     * @return
-     */
-    public String getTag() {return tag;};
-    public int getSpeed() {return speed;};
+    public String getTag() {
+        return tag;
+    }
+
+    public int getSpeed() {
+        return speed;
+    }
 }
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/RoutingLayer.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/RoutingLayer.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/RoutingLayer.java	(revision 32768)
@@ -1,29 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.plugin.routing;
 
@@ -72,15 +46,17 @@
 
     public enum PreferencesKeys {
-        KEY_ACTIVE_ROUTE_COLOR (marktr("routing active route")),
-        KEY_INACTIVE_ROUTE_COLOR (marktr("routing inactive route")),
-        KEY_ROUTE_WIDTH ("routing.route.width"),
-        KEY_ROUTE_SELECT ("routing.route.select");
+        KEY_ACTIVE_ROUTE_COLOR(marktr("routing active route")),
+        KEY_INACTIVE_ROUTE_COLOR(marktr("routing inactive route")),
+        KEY_ROUTE_WIDTH("routing.route.width"),
+        KEY_ROUTE_SELECT("routing.route.select");
 
         public final String key;
-        PreferencesKeys (String key) {
-            this.key=key;
-        }
-
-        public String getKey() {return key;};
+        PreferencesKeys(String key) {
+            this.key = key;
+        }
+
+        public String getKey() {
+            return key;
+        }
     }
 
@@ -103,5 +79,5 @@
      * Start, Middle and End icons
      */
-    private Icon startIcon,middleIcon,endIcon;
+    private Icon startIcon, middleIcon, endIcon;
 
     /**
@@ -117,11 +93,11 @@
         super(name);
         logger.debug("Creating Routing Layer...");
-        if(startIcon == null) startIcon = ImageProvider.get("routing", "startflag");
-        if(middleIcon == null) middleIcon = ImageProvider.get("routing", "middleflag");
-        if(endIcon == null) endIcon = ImageProvider.get("routing", "endflag");
+        if (startIcon == null) startIcon = ImageProvider.get("routing", "startflag");
+        if (middleIcon == null) middleIcon = ImageProvider.get("routing", "middleflag");
+        if (endIcon == null) endIcon = ImageProvider.get("routing", "endflag");
         this.dataLayer = dataLayer;
         this.routingModel = new RoutingModel(dataLayer.data);
         logger.debug("Routing Layer created.");
-        
+
 
         this.routingModel.routingGraph.createGraph();    /* construct the graph right after we we create the layer */
@@ -155,5 +131,5 @@
         double minDist = 0;
         for (Way w : dataLayer.data.getWays()) {
-            if (w.isDeleted() || w.isIncomplete() || w.get("highway")==null) continue;
+            if (w.isDeleted() || w.isIncomplete() || w.get("highway") == null) continue;
             for (Node n : w.getNodes()) {
                 if (n.isDeleted() || n.isIncomplete()) continue;
@@ -181,9 +157,9 @@
     public Object getInfoComponent() {
         String info = "<html>"
-                        + "<body>"
-                            +"Graph Vertex: "+this.routingModel.routingGraph.getVertexCount()+"<br/>"
-                            +"Graph Edges: "+this.routingModel.routingGraph.getEdgeCount()+"<br/>"
-                        + "</body>"
-                    + "</html>";
+                + "<body>"
+                +"Graph Vertex: "+this.routingModel.routingGraph.getVertexCount()+"<br/>"
+                +"Graph Edges: "+this.routingModel.routingGraph.getEdgeCount()+"<br/>"
+                + "</body>"
+                + "</html>";
         return info;
     }
@@ -193,5 +169,5 @@
         Collection<Action> components = new ArrayList<>();
         components.add(LayerListDialog.getInstance().createShowHideLayerAction());
-//        components.add(new JMenuItem(new LayerListDialog.ShowHideMarkerText(this)));
+        //        components.add(new JMenuItem(new LayerListDialog.ShowHideMarkerText(this)));
         components.add(LayerListDialog.getInstance().createDeleteLayerAction());
         components.add(SeparatorLayerAction.INSTANCE);
@@ -241,11 +217,11 @@
         }
         int width = Integer.parseInt(widthString);
-        
-        
+
+
         // draw our graph
         if (isActiveLayer) {
-            if(routingModel != null) {
-                if(routingModel.routingGraph != null && routingModel.routingGraph.getGraph() != null) {
-                    Set<OsmEdge> graphEdges =  routingModel.routingGraph.getGraph().edgeSet();
+            if (routingModel != null) {
+                if (routingModel.routingGraph != null && routingModel.routingGraph.getGraph() != null) {
+                    Set<OsmEdge> graphEdges = routingModel.routingGraph.getGraph().edgeSet();
                     if (!graphEdges.isEmpty()) {
                         Color color2 = ColorHelper.html2color("#00ff00");        /* just green for now  */
@@ -253,19 +229,19 @@
                         Point from = mv.getPoint(firstedge.fromEastNorth());
                         g.drawRect(from.x-4, from.y+4, from.x+4, from.y-4);
-                        for(OsmEdge edge : graphEdges) {
+                        for (OsmEdge edge : graphEdges) {
                             drawGraph(g, mv, edge, color2, width);
                         }
                     }
-                 }
-             }
-        }
-                    
-        
-        if(nodes == null || nodes.size() == 0) return;
-        
+                }
+            }
+        }
+
+
+        if (nodes == null || nodes.size() == 0) return;
+
         // Paint routing path
         List<OsmEdge> routeEdges = routingModel.getRouteEdges();
-        if(routeEdges != null) {
-            for(OsmEdge edge : routeEdges) {
+        if (routeEdges != null) {
+            for (OsmEdge edge : routeEdges) {
                 drawEdge(g, mv, edge, color, width, true);
             }
@@ -279,5 +255,5 @@
 
         // paint middle icons
-        for(int index = 1; index < nodes.size() - 1; ++index) {
+        for (int index = 1; index < nodes.size() - 1; ++index) {
             node = nodes.get(index);
             screen = mv.getPoint(node);
@@ -286,5 +262,5 @@
         }
         // paint end icon
-        if(nodes.size() > 1) {
+        if (nodes.size() > 1) {
             node = nodes.get(nodes.size() - 1);
             screen = mv.getPoint(node);
@@ -304,5 +280,5 @@
     public void destroy() {
         routingModel.reset();
-//      layerAdded = false;
+        //      layerAdded = false;
     }
 
@@ -318,16 +294,17 @@
         to = mv.getPoint(edge.toEastNorth());
 
-            Graphics2D g2d = (Graphics2D)g;
-            g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); // Anti-alias!
-            Stroke oldStroke = g2d.getStroke();
-            g2d.setStroke(new BasicStroke(width)); // thickness
-            g2d.drawLine(from.x, from.y, to.x, to.y);
-            if (showDirection) {
-                double t = Math.atan2(to.y-from.y, to.x-from.x) + Math.PI;
-                g.drawLine(to.x,to.y, (int)(to.x + 10*Math.cos(t-ARROW_PHI)), (int)(to.y + 10*Math.sin(t-ARROW_PHI)));
-                g.drawLine(to.x,to.y, (int)(to.x + 10*Math.cos(t+ARROW_PHI)), (int)(to.y + 10*Math.sin(t+ARROW_PHI)));
-            }
-            g2d.setStroke(oldStroke);
-    }
+        Graphics2D g2d = (Graphics2D) g;
+        g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); // Anti-alias!
+        Stroke oldStroke = g2d.getStroke();
+        g2d.setStroke(new BasicStroke(width)); // thickness
+        g2d.drawLine(from.x, from.y, to.x, to.y);
+        if (showDirection) {
+            double t = Math.atan2(to.y-from.y, to.x-from.x) + Math.PI;
+            g.drawLine(to.x, to.y, (int) (to.x + 10*Math.cos(t-ARROW_PHI)), (int) (to.y + 10*Math.sin(t-ARROW_PHI)));
+            g.drawLine(to.x, to.y, (int) (to.x + 10*Math.cos(t+ARROW_PHI)), (int) (to.y + 10*Math.sin(t+ARROW_PHI)));
+        }
+        g2d.setStroke(oldStroke);
+    }
+
     private void drawGraph(Graphics g, MapView mv, OsmEdge edge, Color col, int width) {
         g.setColor(col);
@@ -336,14 +313,14 @@
         from = mv.getPoint(edge.fromEastNorth());
         to = mv.getPoint(edge.toEastNorth());
-        
-            Graphics2D g2d = (Graphics2D)g;
-            Stroke oldStroke = g2d.getStroke();
-            g2d.setStroke(new BasicStroke(width)); // thickness
-            g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING,RenderingHints.VALUE_ANTIALIAS_ON);  // Anti-alias!
-            g2d.drawLine(from.x, from.y, to.x, to.y);
-            g2d.drawRect(to.x- 4, to.y+4, 4, 4);
-
-            g2d.setStroke(oldStroke);
-     }
-        
+
+        Graphics2D g2d = (Graphics2D) g;
+        Stroke oldStroke = g2d.getStroke();
+        g2d.setStroke(new BasicStroke(width)); // thickness
+        g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); // Anti-alias!
+        g2d.drawLine(from.x, from.y, to.x, to.y);
+        g2d.drawRect(to.x- 4, to.y+4, 4, 4);
+
+        g2d.setStroke(oldStroke);
+    }
+
 }
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/RoutingModel.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/RoutingModel.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/RoutingModel.java	(revision 32768)
@@ -1,29 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.plugin.routing;
 
@@ -56,22 +30,22 @@
      * Graph to calculate route
      */
-    public RoutingGraph routingGraph=null;
+    public RoutingGraph routingGraph = null;
 
     /**
      * List of nodes that the route has to traverse
      */
-    private List<Node> nodes=null;
+    private List<Node> nodes = null;
 
-    private List<OsmEdge> path=null;
+    private List<OsmEdge> path = null;
 
     /**
      * Flag to advise about changes in the selected nodes.
      */
-    private boolean changeNodes=false;
+    private boolean changeNodes = false;
 
     /**
      * Flag to advise about changes in ways.
      */
-    private boolean changeOneway=false;
+    private boolean changeOneway = false;
 
     /**
@@ -98,5 +72,5 @@
     public void addNode(Node node) {
         nodes.add(node);
-        this.changeNodes=true;
+        this.changeNodes = true;
     }
 
@@ -106,7 +80,7 @@
      */
     public void removeNode(int index) {
-        if (nodes.size()>index) {
+        if (nodes.size() > index) {
             nodes.remove(index);
-            this.changeNodes=true;
+            this.changeNodes = true;
         }
     }
@@ -118,7 +92,7 @@
      */
     public void insertNode(int index, Node node) {
-        if (nodes.size()>=index) {
+        if (nodes.size() >= index) {
             nodes.add(index, node);
-            this.changeNodes=true;
+            this.changeNodes = true;
         }
     }
@@ -130,8 +104,8 @@
         List<Node> aux = new ArrayList<>();
         for (Node n : nodes) {
-            aux.add(0,n);
+            aux.add(0, n);
         }
         nodes = aux;
-        this.changeNodes=true;
+        this.changeNodes = true;
     }
 
@@ -141,9 +115,8 @@
      */
     public List<OsmEdge> getRouteEdges() {
-        if (this.changeNodes || path==null)
-        {
-            path=this.routingGraph.applyAlgorithm(nodes, Algorithm.ROUTING_ALG_DIJKSTRA);
-            this.changeNodes=false;
-            this.changeOneway=false;
+        if (this.changeNodes || path == null) {
+            path = this.routingGraph.applyAlgorithm(nodes, Algorithm.ROUTING_ALG_DIJKSTRA);
+            this.changeNodes = false;
+            this.changeOneway = false;
         }
         return path;
@@ -176,5 +149,5 @@
     public void reset() {
         nodes.clear();
-        this.changeNodes=true;
+        this.changeNodes = true;
     }
 
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/RoutingPlugin.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/RoutingPlugin.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/RoutingPlugin.java	(revision 32768)
@@ -1,29 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.plugin.routing;
 
@@ -148,5 +122,5 @@
         }
         logger.debug("Loading routing plugin...");
-        preferenceSettings=new RoutingPreferenceDialog();
+        preferenceSettings = new RoutingPreferenceDialog();
         // Initialize layers list
         layers = new ArrayList<>();
@@ -222,5 +196,5 @@
                 routingDialog.refresh();
             }
-        }else{                                            /*   hide Routing toolbar and dialog window  */
+        } else {                                           /*   hide Routing toolbar and dialog window  */
             menu.disableRestOfItems();
             if (routingDialog != null) {
@@ -250,5 +224,5 @@
     public void layerRemoving(LayerRemoveEvent evt) {
         Layer oldLayer = evt.getRemovedLayer();
-        if ((oldLayer instanceof RoutingLayer) & (layers.size()==1)) {
+        if ((oldLayer instanceof RoutingLayer) & (layers.size() == 1)) {
             // Remove button(s) from the tool bar when the last routing layer is removed
             addRouteNodeButton.setVisible(false);
@@ -263,5 +237,5 @@
             // FIXME: can't remove associated routing layers without triggering exceptions in some cases
             RoutingLayer[] layersArray = layers.toArray(new RoutingLayer[0]);
-            for (int i=0;i<layersArray.length;i++) {
+            for (int i = 0; i < layersArray.length; i++) {
                 if (layersArray[i].getDataLayer().equals(oldLayer)) {
                     try {
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/actions/AddRouteNodeAction.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/actions/AddRouteNodeAction.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/actions/AddRouteNodeAction.java	(revision 32768)
@@ -1,29 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.plugin.routing.actions;
 
@@ -59,5 +33,5 @@
     /**
      * Constructor
-     * @param mapFrame
+     * @param mapFrame map frame
      */
     public AddRouteNodeAction(MapFrame mapFrame) {
@@ -84,7 +58,7 @@
             Node node = null;
             if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
-                RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+                RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
                 node = layer.getNearestHighwayNode(e.getPoint());
-                if(node == null) {
+                if (node == null) {
                     logger.debug("no selected node");
                     return;
@@ -97,4 +71,5 @@
         Main.map.repaint();
     }
+
     @Override public boolean layerIsSupported(Layer l) {
         return l instanceof RoutingLayer;
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/actions/MoveRouteNodeAction.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/actions/MoveRouteNodeAction.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/actions/MoveRouteNodeAction.java	(revision 32768)
@@ -1,29 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.plugin.routing.actions;
 
@@ -39,7 +13,6 @@
 import org.openstreetmap.josm.data.osm.Node;
 import org.openstreetmap.josm.gui.MapFrame;
+import org.openstreetmap.josm.gui.layer.Layer;
 import org.openstreetmap.josm.tools.ImageProvider;
-
-import org.openstreetmap.josm.gui.layer.Layer;
 
 import com.innovant.josm.plugin.routing.RoutingLayer;
@@ -74,5 +47,5 @@
     /**
      * Constructor
-     * @param mapFrame
+     * @param mapFrame map frame
      */
     public MoveRouteNodeAction(MapFrame mapFrame) {
@@ -98,5 +71,5 @@
             if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
                 requestFocusInMapView();
-                RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+                RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
                 RoutingModel routingModel = layer.getRoutingModel();
                 // Search for the nearest node in the list
@@ -104,5 +77,5 @@
                 index = -1;
                 double dmax = DRAG_SQR_RADIUS; // maximum distance, in pixels
-                for (int i=0;i<nl.size();i++) {
+                for (int i = 0; i < nl.size(); i++) {
                     Node node = nl.get(i);
                     double d = Main.map.mapView.getPoint(node).distanceSq(e.getPoint());
@@ -112,5 +85,5 @@
                     }
                 }
-                if (index>=0)
+                if (index >= 0)
                     logger.debug("Moved from node " + nl.get(index));
             }
@@ -120,5 +93,5 @@
     @Override public void mouseReleased(MouseEvent e) {
         // If left button is released and a route node is being dragged
-        if ((e.getButton() == MouseEvent.BUTTON1) && (index>=0)) {
+        if ((e.getButton() == MouseEvent.BUTTON1) && (index >= 0)) {
             searchAndReplaceNode(e.getPoint());
         }
@@ -130,5 +103,5 @@
     private void searchAndReplaceNode(Point point) {
         if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
-            RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+            RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
             RoutingModel routingModel = layer.getRoutingModel();
             RoutingDialog routingDialog = RoutingPlugin.getInstance().getRoutingDialog();
@@ -148,7 +121,7 @@
         }
     }
+
     @Override public boolean layerIsSupported(Layer l) {
         return l instanceof RoutingLayer;
     }
-
 }
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/actions/RemoveRouteNodeAction.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/actions/RemoveRouteNodeAction.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/actions/RemoveRouteNodeAction.java	(revision 32768)
@@ -1,29 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.plugin.routing.actions;
 
@@ -85,5 +59,5 @@
         if (e.getButton() == MouseEvent.BUTTON1) {
             if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
-                RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+                RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
                 RoutingModel routingModel = layer.getRoutingModel();
                 // Search for the nearest node in the list
@@ -91,5 +65,5 @@
                 int index = -1;
                 double dmax = REMOVE_SQR_RADIUS; // maximum distance, in pixels
-                for (int i=0;i<nl.size();i++) {
+                for (int i = 0; i < nl.size(); i++) {
                     Node node = nl.get(i);
                     double d = Main.map.mapView.getPoint(node).distanceSq(e.getPoint());
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/gui/RoutingDialog.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/gui/RoutingDialog.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/gui/RoutingDialog.java	(revision 32768)
@@ -1,29 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.plugin.routing.gui;
 
@@ -99,5 +73,4 @@
     /**
      * Remove item from the list of nodes
-     * @param index
      */
     public void removeNode(int index) {
@@ -107,5 +80,4 @@
     /**
      * Add item to the list of nodes
-     * @param obj
      */
     public void addNode(Node n) {
@@ -115,6 +87,4 @@
     /**
      * Insert item to the list of nodes
-     * @param index
-     * @param obj
      */
     public void insertNode(int index, Node n) {
@@ -132,5 +102,5 @@
         clearNodes();
         if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
-            RoutingLayer routingLayer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+            RoutingLayer routingLayer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
             RoutingModel routingModel = routingLayer.getRoutingModel();
             for (Node n : routingModel.getSelectedNodes()) {
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/gui/RoutingMenu.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/gui/RoutingMenu.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/gui/RoutingMenu.java	(revision 32768)
@@ -1,29 +1,3 @@
-/*
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.plugin.routing.gui;
 
@@ -78,4 +52,5 @@
         startMI = new JMenuItem(tr("Add routing layer"));
         startMI.addActionListener(new ActionListener() {
+            @Override
             public void actionPerformed(ActionEvent e) {
                 RoutingPlugin.getInstance().addLayer();
@@ -92,9 +67,10 @@
         rshorter.setSelected(true);
         rshorter.addItemListener(new ItemListener() {
+            @Override
             public void itemStateChanged(ItemEvent e) {
                 if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
-                    RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+                    RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
                     RoutingModel routingModel = layer.getRoutingModel();
-                    if (e.getStateChange()==ItemEvent.SELECTED) {
+                    if (e.getStateChange() == ItemEvent.SELECTED) {
                         routingModel.routingGraph.setTypeRoute(RouteType.SHORTEST);
                     } else {
@@ -121,9 +97,10 @@
         JCheckBoxMenuItem cbmi = new JCheckBoxMenuItem(tr("Ignore oneways"));
         cbmi.addItemListener(new ItemListener() {
+            @Override
             public void itemStateChanged(ItemEvent e) {
                 if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
-                    RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+                    RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
                     RoutingModel routingModel = layer.getRoutingModel();
-                    if (e.getStateChange()==ItemEvent.SELECTED)
+                    if (e.getStateChange() == ItemEvent.SELECTED)
                         routingModel.routingGraph.getRoutingProfile().setOnewayUse(false);
                     else
@@ -141,7 +118,8 @@
         reverseMI = new JMenuItem(tr("Reverse route"));
         reverseMI.addActionListener(new ActionListener() {
+            @Override
             public void actionPerformed(ActionEvent e) {
                 if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
-                    RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+                    RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
                     RoutingModel routingModel = layer.getRoutingModel();
                     routingModel.reverseNodes();
@@ -154,7 +132,8 @@
         clearMI = new JMenuItem(tr("Clear route"));
         clearMI.addActionListener(new ActionListener() {
+            @Override
             public void actionPerformed(ActionEvent e) {
                 if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
-                    RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+                    RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
                     RoutingModel routingModel = layer.getRoutingModel();
                     // Reset routing nodes and paths
@@ -169,8 +148,9 @@
         regraphMI = new JMenuItem(tr("Reconstruct Graph"));
         regraphMI.addActionListener(new ActionListener() {
+            @Override
             public void actionPerformed(ActionEvent e) {
 
                 if (Main.getLayerManager().getActiveLayer() instanceof RoutingLayer) {
-                    RoutingLayer layer = (RoutingLayer)Main.getLayerManager().getActiveLayer();
+                    RoutingLayer layer = (RoutingLayer) Main.getLayerManager().getActiveLayer();
                     RoutingModel routingModel = layer.getRoutingModel();
                     routingModel.routingGraph.resetGraph();
Index: /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/gui/RoutingPreferenceDialog.java
===================================================================
--- /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/gui/RoutingPreferenceDialog.java	(revision 32767)
+++ /applications/editors/josm/plugins/routing/src/com/innovant/josm/plugin/routing/gui/RoutingPreferenceDialog.java	(revision 32768)
@@ -1,30 +1,3 @@
-/*
- *
- * Copyright (C) 2008 Innovant
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
- *
- * For more information, please contact:
- *
- *  Innovant
- *   juangui@gmail.com
- *   vidalfree@gmail.com
- *
- *  http://public.grupoinnovant.com/blog
- *
- */
-
+// License: GPL. For details, see LICENSE file.
 package com.innovant.josm.plugin.routing.gui;
 
@@ -79,4 +52,5 @@
     }
 
+    @Override
     public void addGui(final PreferenceTabbedPane gui) {
 
@@ -86,5 +60,5 @@
         p.setLayout(new GridBagLayout());
 
-        model = new DefaultTableModel(new String[] { tr("Highway type"),
+        model = new DefaultTableModel(new String[] {tr("Highway type"),
                 tr("Speed (Km/h)") }, 0) {
             private static final long serialVersionUID = 4253339034781567453L;
@@ -107,10 +81,12 @@
         p.add(add, GBC.std().insets(0, 5, 0, 0));
         add.addActionListener(new ActionListener() {
+            @Override
             public void actionPerformed(ActionEvent e) {
                 JPanel p = new JPanel(new GridBagLayout());
                 p.add(new JLabel(tr("Weight")), GBC.std().insets(0, 0, 5, 0));
                 JComboBox<String> key = new JComboBox<>();
-                for (OsmWayTypes pk : OsmWayTypes.values())
+                for (OsmWayTypes pk : OsmWayTypes.values()) {
                     key.addItem(pk.getTag());
+                }
                 JTextField value = new JTextField(10);
                 p.add(key, GBC.eop().insets(5, 0, 0, 0).fill(GBC.HORIZONTAL));
@@ -132,4 +108,5 @@
         p.add(delete, GBC.std().insets(0, 5, 0, 0));
         delete.addActionListener(new ActionListener() {
+            @Override
             public void actionPerformed(ActionEvent e) {
                 if (list.getSelectedRow() == -1)
@@ -138,6 +115,7 @@
                 else {
                     Integer i;
-                    while ((i = list.getSelectedRow()) != -1)
+                    while ((i = list.getSelectedRow()) != -1) {
                         model.removeRow(i);
+                    }
                 }
             }
@@ -147,4 +125,5 @@
         p.add(edit, GBC.std().insets(5, 5, 5, 0));
         edit.addActionListener(new ActionListener() {
+            @Override
             public void actionPerformed(ActionEvent e) {
                 edit(gui, list);
@@ -158,5 +137,5 @@
         //      Opciones.addTab("Preferences", new JPanel());
 
-        list.addMouseListener(new MouseAdapter(){
+        list.addMouseListener(new MouseAdapter() {
             @Override public void mouseClicked(MouseEvent e) {
                 if (e.getClickCount() == 2)
@@ -169,4 +148,5 @@
     }
 
+    @Override
     public boolean ok() {
         for (int i = 0; i < model.getRowCount(); ++i) {
@@ -180,6 +160,7 @@
             }
         }
-        for (Entry<String, String> e : orig.entrySet())
+        for (Entry<String, String> e : orig.entrySet()) {
             Main.pref.put(e.getKey(), null);
+        }
         return false;
     }
@@ -203,5 +184,5 @@
         // Put these values in the model
         for (String tag : orig.keySet()) {
-            model.addRow(new String[] { tag, orig.get(tag) });
+            model.addRow(new String[] {tag, orig.get(tag)});
         }
     }
@@ -216,6 +197,5 @@
             }
             orig = Main.pref.getAllPrefix("routing.profile.default.speed");
-        }
-        else logger.debug("Default preferences already exist.");
+        } else logger.debug("Default preferences already exist.");
     }
     /*
