Ignore:
Timestamp:
2012-08-11T17:37:00+02:00 (12 years ago)
Author:
Don-vip
Message:

see #7943 - Introduce OsmApi.DEFAULT_API_URL, better handling of change of API URL in OAuth management, javadoc improvements

File:
1 edited

Legend:

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

    r5386 r5422  
    6161     * <a href="http://wiki.openstreetmap.org/wiki/API_usage_policy#Technical_Usage_Requirements">
    6262     * OSM API usage policy.</a>
     63     * @since 5386
    6364     */
    6465    static public final int MAX_DOWNLOAD_THREADS = 2;
     66   
     67    /**
     68     * Default URL of the standard OSM API.
     69     * @since 5422
     70     */
     71    static public final String DEFAULT_API_URL = "http://api.openstreetmap.org/api";
    6572
    6673    // The collection of instantiated OSM APIs
     
    9299     */
    93100    static public OsmApi getOsmApi() {
    94         String serverUrl = Main.pref.get("osm-server.url", "http://api.openstreetmap.org/api");
     101        String serverUrl = Main.pref.get("osm-server.url", DEFAULT_API_URL);
    95102        if (serverUrl == null)
    96103            throw new IllegalStateException(tr("Preference ''{0}'' missing. Cannot initialize OsmApi.", "osm-server.url"));
Note: See TracChangeset for help on using the changeset viewer.