diff options
author | Bananeweizen <Bananeweizen@gmx.de> | 2012-04-12 19:31:13 +0200 |
---|---|---|
committer | Bananeweizen <Bananeweizen@gmx.de> | 2012-04-12 19:31:13 +0200 |
commit | b2f4fa6db9e262d087d715c497b1241833a0599d (patch) | |
tree | c3972bf51ce2776cfca4d564d05f5eb66a1fbe64 /main/src/cgeo/geocaching/connector | |
parent | 90a0c8b78f121ddf7295a97e257aa2605a371434 (diff) | |
download | cgeo-b2f4fa6db9e262d087d715c497b1241833a0599d.zip cgeo-b2f4fa6db9e262d087d715c497b1241833a0599d.tar.gz cgeo-b2f4fa6db9e262d087d715c497b1241833a0599d.tar.bz2 |
refactoring: remove the logging tag from settings
Diffstat (limited to 'main/src/cgeo/geocaching/connector')
4 files changed, 15 insertions, 17 deletions
diff --git a/main/src/cgeo/geocaching/connector/gc/GCBase.java b/main/src/cgeo/geocaching/connector/gc/GCBase.java index 3ecd31a..9d5ee3e 100644 --- a/main/src/cgeo/geocaching/connector/gc/GCBase.java +++ b/main/src/cgeo/geocaching/connector/gc/GCBase.java @@ -113,7 +113,7 @@ public class GCBase { * @return */ private static SearchResult searchByViewport(final Viewport viewport, final String[] tokens, Strategy strategy) { - Log.d(Settings.tag, "GCBase.searchByViewport" + viewport.toString()); + Log.d("GCBase.searchByViewport" + viewport.toString()); String referer = GCConstants.URL_LIVE_MAP; @@ -166,11 +166,11 @@ public class GCBase { String data = Tile.requestMapInfo(GCConstants.URL_MAP_INFO + urlString, referer); if (StringUtils.isEmpty(data)) { - Log.e(Settings.tag, "GCBase.searchByViewport: No data from server for tile (" + tile.getX() + "/" + tile.getY() + ")"); + Log.e("GCBase.searchByViewport: No data from server for tile (" + tile.getX() + "/" + tile.getY() + ")"); } else { final SearchResult search = parseMapJSON(data, tile, bitmap, strategy); if (search == null || CollectionUtils.isEmpty(search.getGeocodes())) { - Log.e(Settings.tag, "GCBase.searchByViewport: No cache parsed for viewport " + viewport); + Log.e("GCBase.searchByViewport: No cache parsed for viewport " + viewport); } else { searchResult.addGeocodes(search.getGeocodes()); @@ -308,10 +308,10 @@ public class GCBase { } searchResult.addCache(cache); } - Log.d(Settings.tag, "Retrieved " + searchResult.getCount() + " caches for tile " + tile.toString()); + Log.d("Retrieved " + searchResult.getCount() + " caches for tile " + tile.toString()); } catch (Exception e) { - Log.e(Settings.tag, "GCBase.parseMapJSON", e); + Log.e("GCBase.parseMapJSON", e); } return searchResult; diff --git a/main/src/cgeo/geocaching/connector/gc/GCConnector.java b/main/src/cgeo/geocaching/connector/gc/GCConnector.java index d955418..4794654 100644 --- a/main/src/cgeo/geocaching/connector/gc/GCConnector.java +++ b/main/src/cgeo/geocaching/connector/gc/GCConnector.java @@ -90,7 +90,7 @@ public class GCConnector extends AbstractConnector { public SearchResult searchByGeocode(final String geocode, final String guid, final cgeoapplication app, final CancellableHandler handler) { if (app == null) { - Log.e(Settings.tag, "cgeoBase.searchByGeocode: No application found"); + Log.e("cgeoBase.searchByGeocode: No application found"); return null; } @@ -111,7 +111,7 @@ public class GCConnector extends AbstractConnector { final SearchResult search = new SearchResult(); if (app.isThere(geocode, guid, true, false)) { if (StringUtils.isBlank(geocode) && StringUtils.isNotBlank(guid)) { - Log.i(Settings.tag, "Loading old cache from cache."); + Log.i("Loading old cache from cache."); search.addGeocode(app.getGeocode(guid)); } else { @@ -121,7 +121,7 @@ public class GCConnector extends AbstractConnector { return search; } - Log.e(Settings.tag, "cgeoBase.searchByGeocode: No data from server"); + Log.e("cgeoBase.searchByGeocode: No data from server"); search.setError(StatusCode.COMMUNICATION_ERROR); return search; } @@ -129,7 +129,7 @@ public class GCConnector extends AbstractConnector { final SearchResult searchResult = cgBase.parseCache(page, handler); if (searchResult == null || CollectionUtils.isEmpty(searchResult.getGeocodes())) { - Log.e(Settings.tag, "cgeoBase.searchByGeocode: No cache parsed"); + Log.e("cgeoBase.searchByGeocode: No cache parsed"); return searchResult; } diff --git a/main/src/cgeo/geocaching/connector/gc/Tile.java b/main/src/cgeo/geocaching/connector/gc/Tile.java index 27b45de..fd51839 100644 --- a/main/src/cgeo/geocaching/connector/gc/Tile.java +++ b/main/src/cgeo/geocaching/connector/gc/Tile.java @@ -1,6 +1,5 @@ package cgeo.geocaching.connector.gc; -import cgeo.geocaching.Settings; import cgeo.geocaching.geopoint.Geopoint; import cgeo.geocaching.geopoint.Viewport; import cgeo.geocaching.network.Network; @@ -226,7 +225,7 @@ public class Tile { try { return response != null ? BitmapFactory.decodeStream(response.getEntity().getContent()) : null; } catch (IOException e) { - Log.e(Settings.tag, "cgBase.requestMapTile() " + e.getMessage()); + Log.e("cgBase.requestMapTile() " + e.getMessage()); } return null; } diff --git a/main/src/cgeo/geocaching/connector/opencaching/OkapiClient.java b/main/src/cgeo/geocaching/connector/opencaching/OkapiClient.java index 7c1138a..80786f9 100644 --- a/main/src/cgeo/geocaching/connector/opencaching/OkapiClient.java +++ b/main/src/cgeo/geocaching/connector/opencaching/OkapiClient.java @@ -1,6 +1,5 @@ package cgeo.geocaching.connector.opencaching; -import cgeo.geocaching.Settings; import cgeo.geocaching.cgCache; import cgeo.geocaching.cgImage; import cgeo.geocaching.cgLog; @@ -114,7 +113,7 @@ final public class OkapiClient { return caches; } } catch (JSONException e) { - Log.e(Settings.tag, "OkapiClient.parseCaches", e); + Log.e("OkapiClient.parseCaches", e); } return null; } @@ -181,7 +180,7 @@ final public class OkapiClient { // save full detailed caches cgeoapplication.getInstance().saveCache(cache, EnumSet.of(SaveFlag.SAVE_DB)); } catch (JSONException e) { - Log.e(Settings.tag, "OkapiClient.parseCache", e); + Log.e("OkapiClient.parseCache", e); } return cache; } @@ -218,7 +217,7 @@ final public class OkapiClient { } result.add(log); } catch (JSONException e) { - Log.e(Settings.tag, "OkapiClient.parseLogs", e); + Log.e("OkapiClient.parseLogs", e); } } return result; @@ -240,7 +239,7 @@ final public class OkapiClient { try { return ISO8601DATEFORMAT.parse(strippedDate); } catch (ParseException e) { - Log.e(Settings.tag, "OkapiClient.parseDate", e); + Log.e("OkapiClient.parseDate", e); } return null; } @@ -260,7 +259,7 @@ final public class OkapiClient { try { size = response.getDouble(CACHE_SIZE); } catch (JSONException e) { - Log.e(Settings.tag, "OkapiClient.getCacheSize", e); + Log.e("OkapiClient.getCacheSize", e); } switch ((int) Math.round(size)) { case 1: |