Index: trunk/src/org/openstreetmap/josm/data/imagery/GetCapabilitiesParseHelper.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/imagery/GetCapabilitiesParseHelper.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/data/imagery/GetCapabilitiesParseHelper.java	(revision 13742)
@@ -117,5 +117,5 @@
      * @param reader XMLStreamReader that should point to start of element
      * @return content of current tag
-     * @throws XMLStreamException
+     * @throws XMLStreamException if any XML stream error occurs
      */
     public static String getElementTextWithSubtags(XMLStreamReader reader) throws XMLStreamException {
Index: trunk/src/org/openstreetmap/josm/data/imagery/ImageryInfo.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/imagery/ImageryInfo.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/data/imagery/ImageryInfo.java	(revision 13742)
@@ -1432,5 +1432,5 @@
     /**
      * Sets custom HTTP headers that should be sent with request towards imagery provider
-     * @param customHttpHeaders
+     * @param customHttpHeaders http headers
      */
     public void setCustomHttpHeaders(Map<String, String> customHttpHeaders) {
@@ -1462,5 +1462,5 @@
     /**
      * Sets minimum tile expiration in seconds
-     * @param minimumTileExpire
+     * @param minimumTileExpire minimum tile expiration in seconds
      */
     public void setMinimumTileExpire(int minimumTileExpire) {
Index: trunk/src/org/openstreetmap/josm/data/imagery/LayerDetails.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/imagery/LayerDetails.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/data/imagery/LayerDetails.java	(revision 13742)
@@ -38,5 +38,5 @@
      * This is needed to properly handle layer attributes inheritance.
      *
-     * @param parentLayer
+     * @param parentLayer parent layer
      */
     public LayerDetails(LayerDetails parentLayer) {
@@ -70,6 +70,6 @@
 
     /**
+     * @return title "Human readable" title of this layer
      * @see LayerDetails#getName()
-     * @return title "Human readable" title of this layer
      */
     public String getTitle() {
@@ -78,6 +78,6 @@
 
     /**
+     * @param title set title of this layer
      * @see LayerDetails#getName()
-     * @param title set title of this layer
      */
     public void setTitle(String title) {
@@ -88,11 +88,11 @@
      *
      * Citation from OGC WMS specification (WMS 1.3.0):
-     * > A number of elements have both a <Name> and a <Title>. The Name is a text string used for machine-to-machine
+     * > A number of elements have both a {@literal <Name>} and a {@literal <Title>}. The Name is a text string used for machine-to-machine
      * > communication while the Title is for the benefit of humans. For example, a dataset might have the descriptive Title
      * > “Maximum Atmospheric Temperature” and be requested using the abbreviated Name “ATMAX”.
      *
      * And second citation:
-     * > If, and only if, a layer has a <Name>, then it is a map layer that can be requested by using that Name in the
-     * > LAYERS parameter of a GetMap request. A Layer that contains a <Name> element is referred to as a “named
+     * > If, and only if, a layer has a {@literal <Name>}, then it is a map layer that can be requested by using that Name in the
+     * > LAYERS parameter of a GetMap request. A Layer that contains a {@literal <Name>} element is referred to as a “named
      * > layer” in this International Standard. If the layer has a Title but no Name, then that layer is only a category title for
      * > all the layers nested within.
@@ -104,6 +104,6 @@
 
     /**
+     * @param name sets the name of this Layer
      * @see LayerDetails#getName()
-     * @param name sets the name of this Layer
      */
     public void setName(String name) {
@@ -138,5 +138,5 @@
     /**
      * sets bounds of this layer
-     * @param bounds
+     * @param bounds of this layer
      */
     public void setBounds(Bounds bounds) {
@@ -160,5 +160,5 @@
     /**
      * sets children layers for this layer
-     * @param children
+     * @param children children of this layer
      */
     public void setChildren(List<LayerDetails> children) {
@@ -192,5 +192,5 @@
     /**
      * Sets abstract of this layer
-     * @param abstr
+     * @param abstr abstract of this layer
      */
     public void setAbstract(String abstr) {
Index: trunk/src/org/openstreetmap/josm/data/imagery/TileJobOptions.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/imagery/TileJobOptions.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/data/imagery/TileJobOptions.java	(revision 13742)
@@ -23,5 +23,5 @@
      * @param connectTimeout in milliseconds
      * @param readTimeout in milliseconds
-     * @param headers
+     * @param headers http headers
      * @param minimumExpiryTime in seconds
      */
Index: trunk/src/org/openstreetmap/josm/data/imagery/WMSEndpointTileSource.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/imagery/WMSEndpointTileSource.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/data/imagery/WMSEndpointTileSource.java	(revision 13742)
@@ -31,5 +31,5 @@
     private List<DefaultLayer> layers;
     private String urlPattern;
-    private static final Pattern PATTERN_PARAM  = Pattern.compile("\\{([^}]+)\\}");
+    private static final Pattern PATTERN_PARAM = Pattern.compile("\\{([^}]+)\\}");
     private final Map<String, String> headers = new ConcurrentHashMap<>();
 
Index: trunk/src/org/openstreetmap/josm/data/imagery/WMTSTileSource.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/imagery/WMTSTileSource.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/data/imagery/WMTSTileSource.java	(revision 13742)
@@ -303,5 +303,5 @@
      * @param info imagery info
      * @throws IOException if any I/O error occurs
-     * @throws WMTSGetCapabilitiesException
+     * @throws WMTSGetCapabilitiesException when document didn't contain any layers
      * @throws IllegalArgumentException if any other error happens for the given imagery info
      */
@@ -312,5 +312,5 @@
         this.baseUrl = GetCapabilitiesParseHelper.normalizeCapabilitiesUrl(handleTemplate(info.getUrl()));
         WMTSCapabilities capabilities = getCapabilities(baseUrl, headers);
-        this.layers =  capabilities.getLayers();
+        this.layers = capabilities.getLayers();
         this.baseUrl = capabilities.getBaseUrl();
         this.transferMode = capabilities.getTransferMode();
@@ -374,5 +374,5 @@
      * @return capabilities
      * @throws IOException in case of any I/O error
-     * @throws WMTSGetCapabilitiesException
+     * @throws WMTSGetCapabilitiesException when document didn't contain any layers
      * @throws IllegalArgumentException in case of any other error
      */
Index: trunk/src/org/openstreetmap/josm/gui/layer/WMSLayer.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/layer/WMSLayer.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/gui/layer/WMSLayer.java	(revision 13742)
@@ -66,5 +66,6 @@
     public WMSLayer(ImageryInfo info) {
         super(info);
-        CheckParameterUtil.ensureThat(info.getImageryType() == ImageryType.WMS || info.getImageryType() == ImageryType.WMS_ENDPOINT, "ImageryType is WMS");
+        CheckParameterUtil.ensureThat(
+                info.getImageryType() == ImageryType.WMS || info.getImageryType() == ImageryType.WMS_ENDPOINT, "ImageryType is WMS");
         CheckParameterUtil.ensureParameterNotNull(info.getUrl(), "info.url");
         if (info.getImageryType() == ImageryType.WMS) {
Index: trunk/src/org/openstreetmap/josm/gui/preferences/imagery/AddImageryPanel.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/preferences/imagery/AddImageryPanel.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/gui/preferences/imagery/AddImageryPanel.java	(revision 13742)
@@ -48,5 +48,5 @@
     protected final transient Collection<ContentValidationListener> listeners = new ArrayList<>();
 
-    private final JCheckBox validGeoreference= new JCheckBox(tr("Is layer properly georeferenced?"));
+    private final JCheckBox validGeoreference = new JCheckBox(tr("Is layer properly georeferenced?"));
     private HeadersTable headersTable;
     private JSpinner minimumCacheExpiry;
@@ -72,5 +72,5 @@
         headersTable = new HeadersTable();
         minimumCacheExpiry = new JSpinner(new SpinnerNumberModel(
-                (Number)TimeUnit.MILLISECONDS.toSeconds(TMSCachedTileLoaderJob.MINIMUM_EXPIRES.get()),
+                (Number) TimeUnit.MILLISECONDS.toSeconds(TMSCachedTileLoaderJob.MINIMUM_EXPIRES.get()),
                 0L,
                 Long.valueOf(Integer.MAX_VALUE),
@@ -101,5 +101,5 @@
                     break;
                 default:
-                    Logging.warn("Dupa: " + units.indexOf(e.getItem()));
+                    Logging.warn("Unkown unit: " + units.indexOf(e.getItem()));
                 }
                 minimumCacheExpiry.setValue(newValue);
Index: trunk/src/org/openstreetmap/josm/gui/preferences/imagery/AddWMTSLayerPanel.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/preferences/imagery/AddWMTSLayerPanel.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/gui/preferences/imagery/AddWMTSLayerPanel.java	(revision 13742)
@@ -100,5 +100,5 @@
             Layer selectedLayer = layers.get(layerTable.convertRowIndexToModel(index)).getValue().get(0);
             ret.setDefaultLayers(
-                    Collections.<DefaultLayer> singletonList(
+                    Collections.<DefaultLayer>singletonList(
                             new DefaultLayer(
                                     ImageryType.WMTS,
Index: trunk/src/org/openstreetmap/josm/gui/preferences/imagery/HeadersTable.java
===================================================================
--- trunk/src/org/openstreetmap/josm/gui/preferences/imagery/HeadersTable.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/gui/preferences/imagery/HeadersTable.java	(revision 13742)
@@ -72,5 +72,5 @@
 
             } else if (row == headers.size()) {
-                String[] entry = new String[] { "", "" };
+                String[] entry = new String[] {"", ""};
                 entry[col] = (String) value;
                 headers.add(entry);
@@ -93,5 +93,5 @@
     /**
      * Create table prefilled with headers
-     * @param headers
+     * @param headers contents of table
      */
     public HeadersTable(Map<String, String> headers) {
@@ -108,5 +108,5 @@
     private static List<String[]> getHeadersAsVector(Map<String, String> headers) {
         return headers.entrySet().stream().sorted((e1, e2) -> e1.getKey().compareTo(e2.getKey()))
-                .map(e -> new String[] { e.getKey(), e.getValue() }).collect(Collectors.toList());
+                .map(e -> new String[] {e.getKey(), e.getValue()}).collect(Collectors.toList());
     }
 
Index: trunk/src/org/openstreetmap/josm/io/imagery/ImageryReader.java
===================================================================
--- trunk/src/org/openstreetmap/josm/io/imagery/ImageryReader.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/io/imagery/ImageryReader.java	(revision 13742)
@@ -290,5 +290,10 @@
                 if ("layer".equals(qName)) {
                     newState = State.NOOP;
-                    defaultLayers.add(new DefaultLayer(entry.getImageryType(), atts.getValue("name"),atts.getValue("style"), atts.getValue("tileMatrixSet")));
+                    defaultLayers.add(new DefaultLayer(
+                            entry.getImageryType(),
+                            atts.getValue("name"),
+                            atts.getValue("style"),
+                            atts.getValue("tileMatrixSet")
+                            ));
                 }
                 break;
Index: trunk/src/org/openstreetmap/josm/io/imagery/WMSImagery.java
===================================================================
--- trunk/src/org/openstreetmap/josm/io/imagery/WMSImagery.java	(revision 13741)
+++ trunk/src/org/openstreetmap/josm/io/imagery/WMSImagery.java	(revision 13742)
@@ -132,6 +132,6 @@
      * Make getCapabilities request towards given URL
      * @param url service url
-     * @throws IOException
-     * @throws WMSGetCapabilitiesException
+     * @throws IOException when connection error when fetching get capabilities document
+     * @throws WMSGetCapabilitiesException when there are errors when parsing get capabilities document
      */
     public WMSImagery(String url) throws IOException, WMSGetCapabilitiesException {
@@ -143,6 +143,6 @@
      * @param url service url
      * @param headers HTTP headers to be sent with request
-     * @throws IOException
-     * @throws WMSGetCapabilitiesException
+     * @throws IOException when connection error when fetching get capabilities document
+     * @throws WMSGetCapabilitiesException when there are errors when parsing get capabilities document
      */
     public WMSImagery(String url, Map<String, String> headers) throws IOException, WMSGetCapabilitiesException {
@@ -185,4 +185,5 @@
                 } catch (MalformedURLException e1) { // NOPMD
                     // do nothing, raise original exception
+                    Logging.trace(e1);
                 }
             }
@@ -287,10 +288,9 @@
 
     /**
-     * @see #buildGetMapUrl(List, boolean)
-     *
      * @param selectedLayers selected layers as subset of the tree returned by {@link #getLayers()}
      * @param selectedStyles selected styles for all selectedLayers
      * @param transparent whether returned images should contain transparent pixels (if supported by format)
      * @return URL template for GetMap service
+     * @see #buildGetMapUrl(List, boolean)
      */
     public String buildGetMapUrl(List<LayerDetails> selectedLayers, List<String> selectedStyles, boolean transparent) {
@@ -303,6 +303,4 @@
 
     /**
-     * @see #buildGetMapUrl(List, boolean)
-     *
      * @param selectedLayers selected layers as list of strings
      * @param selectedStyles selected styles of layers as list of strings
@@ -310,4 +308,5 @@
      * @param transparent whether returned images should contain transparent pixels (if supported by format)
      * @return URL template for GetMap service
+     * @see #buildGetMapUrl(List, boolean)
      */
     public String buildGetMapUrl(List<String> selectedLayers,
@@ -385,4 +384,5 @@
         if (GetCapabilitiesParseHelper.moveReaderToTag(reader, this::tagEquals, QN_TITLE)) {
             this.title = reader.getElementText();
+            // CHECKSTYLE.OFF: EmptyBlock
             for (int event = reader.getEventType();
                     reader.hasNext() && !(event == XMLStreamReader.END_ELEMENT && tagEquals(QN_SERVICE, reader.getName()));
@@ -390,4 +390,5 @@
                 // empty loop, just move reader to the end of Service tag, if moveReaderToTag return false, it's already done
             }
+            // CHECKSTYLE.ON: EmptyBlock
         }
     }
@@ -591,5 +592,4 @@
     }
 
-
     private String normalizeUrl(String serviceUrlStr) throws MalformedURLException {
         URL getCapabilitiesUrl = null;
@@ -641,5 +641,4 @@
     }
 
-
     static boolean imageFormatHasTransparency(final String format) {
         return format != null && (format.startsWith("image/png") || format.startsWith("image/gif")
@@ -686,5 +685,5 @@
 
     /**
-     * @param defaultLayers
+     * @param defaultLayers default layers that should select layer object
      * @return collection of LayerDetails specified by DefaultLayers
      */
