Index: /trunk/src/org/openstreetmap/josm/io/imagery/WMSImagery.java
===================================================================
--- /trunk/src/org/openstreetmap/josm/io/imagery/WMSImagery.java	(revision 12474)
+++ /trunk/src/org/openstreetmap/josm/io/imagery/WMSImagery.java	(revision 12475)
@@ -173,8 +173,19 @@
     }
 
+    /**
+     * Returns the URL for the "GetMap" WMS request in JPEG format.
+     * @param selectedLayers the list of selected layers, matching the "LAYERS" WMS request argument
+     * @return the URL for the "GetMap" WMS request
+     */
     public String buildGetMapUrl(Collection<LayerDetails> selectedLayers) {
         return buildGetMapUrl(selectedLayers, "image/jpeg");
     }
 
+    /**
+     * Returns the URL for the "GetMap" WMS request.
+     * @param selectedLayers the list of selected layers, matching the "LAYERS" WMS request argument
+     * @param format the requested image format, matching the "FORMAT" WMS request argument
+     * @return the URL for the "GetMap" WMS request
+     */
     public String buildGetMapUrl(Collection<LayerDetails> selectedLayers, String format) {
         return buildRootUrl() + "FORMAT=" + format + (imageFormatHasTransparency(format) ? "&TRANSPARENT=TRUE" : "")
@@ -184,4 +195,10 @@
     }
 
+    /**
+     * Attempts WMS "GetCapabilities" request and initializes internal variables if successful.
+     * @param serviceUrlStr WMS service URL
+     * @throws IOException if any I/O errors occurs
+     * @throws WMSGetCapabilitiesException if the WMS server replies a ServiceException
+     */
     public void attemptGetCapabilities(String serviceUrlStr) throws IOException, WMSGetCapabilitiesException {
         URL getCapabilitiesUrl = null;
@@ -288,4 +305,10 @@
     }
 
+    /**
+     * Returns a new {@code ImageryInfo} describing the given service name and selected WMS layers.
+     * @param name service name
+     * @param selectedLayers selected WMS layers
+     * @return a new {@code ImageryInfo} describing the given service name and selected WMS layers
+     */
     public ImageryInfo toImageryInfo(String name, Collection<LayerDetails> selectedLayers) {
         ImageryInfo i = new ImageryInfo(name, buildGetMapUrl(selectedLayers));
@@ -345,5 +368,5 @@
             bboxElem = getChild(element, "LatLonBoundingBox");
             if (bboxElem != null) {
-                double left = getDecimalDegree(bboxElem ,"minx");
+                double left = getDecimalDegree(bboxElem, "minx");
                 double top = getDecimalDegree(bboxElem, "maxy");
                 double right = getDecimalDegree(bboxElem, "maxx");
