Ignore:
Timestamp:
2013-09-23T16:47:50+02:00 (11 years ago)
Author:
Don-vip
Message:

Rework console output:

  • new log level "error"
  • Replace nearly all calls to system.out and system.err to Main.(error|warn|info|debug)
  • Remove some unnecessary debug output
  • Some messages are modified (removal of "Info", "Warning", "Error" from the message itself -> notable i18n impact but limited to console error messages not seen by the majority of users, so that's ok)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/io/imagery/WMSImagery.java

    r6106 r6248  
    2020import javax.xml.parsers.DocumentBuilderFactory;
    2121
     22import org.openstreetmap.josm.Main;
    2223import org.openstreetmap.josm.data.Bounds;
    2324import org.openstreetmap.josm.data.imagery.ImageryInfo;
     
    127128        }
    128129
    129         System.out.println("GET " + getCapabilitiesUrl.toString());
     130        Main.info("GET " + getCapabilitiesUrl.toString());
    130131        URLConnection openConnection = Utils.openHttpConnection(getCapabilitiesUrl);
    131132        InputStream inputStream = openConnection.getInputStream();
     
    139140        String incomingData = ba.toString();
    140141
    141         //System.out.println("WMS capabilities:\n"+incomingData+"\n");
    142142        try {
    143143            DocumentBuilderFactory builderFactory = DocumentBuilderFactory.newInstance();
     
    149149                @Override
    150150                public InputSource resolveEntity(String publicId, String systemId) throws SAXException, IOException {
    151                     System.out.println("Ignoring DTD " + publicId + ", " + systemId);
     151                    Main.info("Ignoring DTD " + publicId + ", " + systemId);
    152152                    return new InputSource(new StringReader(""));
    153153                }
     
    175175                String baseURL = child.getAttribute("xlink:href");
    176176                if (baseURL != null && !baseURL.equals(serviceUrlStr)) {
    177                     System.out.println("GetCapabilities specifies a different service URL: " + baseURL);
     177                    Main.info("GetCapabilities specifies a different service URL: " + baseURL);
    178178                    serviceUrl = new URL(baseURL);
    179179                }
Note: See TracChangeset for help on using the changeset viewer.