refactor 'final static' to 'static final' convention
This commit is contained in:
@@ -31,7 +31,7 @@ import org.slf4j.LoggerFactory;
|
||||
|
||||
public class App extends Application {
|
||||
|
||||
public final static Logger log = LoggerFactory.getLogger(App.class);
|
||||
public static final Logger log = LoggerFactory.getLogger(App.class);
|
||||
|
||||
public static Map map;
|
||||
public static MapView view;
|
||||
|
||||
@@ -43,7 +43,7 @@ import org.slf4j.LoggerFactory;
|
||||
|
||||
public class MapLayers {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(MapLayers.class);
|
||||
static final Logger log = LoggerFactory.getLogger(MapLayers.class);
|
||||
|
||||
abstract static class Config {
|
||||
final String name;
|
||||
|
||||
@@ -48,11 +48,11 @@ public class POISearch {
|
||||
ItemizedOverlayWithBubble<ExtendedMarkerItem> poiMarkers;
|
||||
MarkerSymbol[] mMarkers;
|
||||
|
||||
private final static int MDEFAULT = 0;
|
||||
private final static int MFLICKR = 1;
|
||||
private final static int MPICASA = 2;
|
||||
private final static int MWIKI16 = 3;
|
||||
private final static int MWIKI32 = 4;
|
||||
private static final int MDEFAULT = 0;
|
||||
private static final int MFLICKR = 1;
|
||||
private static final int MPICASA = 2;
|
||||
private static final int MWIKI16 = 3;
|
||||
private static final int MWIKI32 = 4;
|
||||
|
||||
POISearch() {
|
||||
mPOIs = new ArrayList<POI>();
|
||||
@@ -89,12 +89,12 @@ public class POISearch {
|
||||
return mPOIs;
|
||||
}
|
||||
|
||||
final static String TAG_WIKIPEDIA = "wikipedia";
|
||||
final static String TAG_FLICKR = "flickr";
|
||||
final static String TAG_PICASA = "picasa";
|
||||
final static String TAG_FOURSQUARE = "foursquare";
|
||||
static final String TAG_WIKIPEDIA = "wikipedia";
|
||||
static final String TAG_FLICKR = "flickr";
|
||||
static final String TAG_PICASA = "picasa";
|
||||
static final String TAG_FOURSQUARE = "foursquare";
|
||||
|
||||
//private final static String TAG_NOMINATIM = "nominatim";
|
||||
//private static final String TAG_NOMINATIM = "nominatim";
|
||||
|
||||
class POITask extends AsyncTask<Object, Void, List<POI>> {
|
||||
String mTag;
|
||||
|
||||
@@ -49,7 +49,7 @@ import org.slf4j.LoggerFactory;
|
||||
import java.util.Map;
|
||||
|
||||
public class TileMap extends MapActivity implements MapEventsReceiver {
|
||||
final static Logger log = LoggerFactory.getLogger(TileMap.class);
|
||||
static final Logger log = LoggerFactory.getLogger(TileMap.class);
|
||||
|
||||
private static final int DIALOG_ENTER_COORDINATES = 0;
|
||||
private static final int DIALOG_LOCATION_PROVIDER_DISABLED = 2;
|
||||
|
||||
@@ -38,7 +38,7 @@ import org.oscim.utils.FastMath;
|
||||
public class Compass extends Layer implements SensorEventListener, Map.UpdateListener,
|
||||
LocationRenderer.Callback {
|
||||
|
||||
// final static Logger log = LoggerFactory.getLogger(Compass.class);
|
||||
// static final Logger log = LoggerFactory.getLogger(Compass.class);
|
||||
|
||||
public enum Mode {
|
||||
OFF, C2D, C3D,
|
||||
|
||||
@@ -32,7 +32,7 @@ import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
public class LocationHandler implements LocationListener {
|
||||
private final static Logger log = LoggerFactory.getLogger(LocationHandler.class);
|
||||
private static final Logger log = LoggerFactory.getLogger(LocationHandler.class);
|
||||
|
||||
public enum Mode {
|
||||
OFF,
|
||||
@@ -40,8 +40,8 @@ public class LocationHandler implements LocationListener {
|
||||
SNAP,
|
||||
}
|
||||
|
||||
private final static int DIALOG_LOCATION_PROVIDER_DISABLED = 2;
|
||||
private final static int SHOW_LOCATION_ZOOM = 14;
|
||||
private static final int DIALOG_LOCATION_PROVIDER_DISABLED = 2;
|
||||
private static final int SHOW_LOCATION_ZOOM = 14;
|
||||
|
||||
private final LocationManager mLocationManager;
|
||||
private final LocationLayerImpl mLocationLayer;
|
||||
|
||||
@@ -18,7 +18,7 @@ import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
public class CacheSizePreference extends Preference implements OnSeekBarChangeListener {
|
||||
final static Logger log = LoggerFactory.getLogger(CacheSizePreference.class);
|
||||
static final Logger log = LoggerFactory.getLogger(CacheSizePreference.class);
|
||||
|
||||
private static final String NS_OCIM_APP = "http://app.oscim.org";
|
||||
private static final int DEFAULT_VALUE = 50;
|
||||
|
||||
@@ -38,7 +38,7 @@ public class DistanceTouchOverlay extends Layer implements Map.InputListener,
|
||||
private float mPrevX1, mPrevX2, mPrevY1, mPrevY2;
|
||||
private float mCurX1, mCurX2, mCurY1, mCurY2;
|
||||
|
||||
// private final static int POINTER_UP = -1;
|
||||
// private static final int POINTER_UP = -1;
|
||||
// private int mPointer1 = POINTER_UP;
|
||||
// private int mPointer2 = POINTER_UP;
|
||||
|
||||
|
||||
@@ -20,10 +20,10 @@ import java.util.HashMap;
|
||||
*/
|
||||
public class FlickrPOIProvider implements POIProvider {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(FlickrPOIProvider.class);
|
||||
static final Logger log = LoggerFactory.getLogger(FlickrPOIProvider.class);
|
||||
|
||||
protected String mApiKey;
|
||||
private final static String PHOTO_URL = "http://www.flickr.com/photos/%s/%s/sizes/o/in/photostream/";
|
||||
private static final String PHOTO_URL = "http://www.flickr.com/photos/%s/%s/sizes/o/in/photostream/";
|
||||
|
||||
/**
|
||||
* @param apiKey the registered API key to give to Flickr service.
|
||||
|
||||
@@ -37,7 +37,7 @@ import java.util.ArrayList;
|
||||
|
||||
public class FourSquareProvider implements POIProvider {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(FourSquareProvider.class);
|
||||
static final Logger log = LoggerFactory.getLogger(FourSquareProvider.class);
|
||||
|
||||
// https://developer.foursquare.com/docs/venues/search
|
||||
// https://developer.foursquare.com/docs/responses/venue
|
||||
|
||||
@@ -31,7 +31,7 @@ import javax.xml.parsers.SAXParserFactory;
|
||||
*/
|
||||
public class GeoNamesPOIProvider {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(GeoNamesPOIProvider.class);
|
||||
static final Logger log = LoggerFactory.getLogger(GeoNamesPOIProvider.class);
|
||||
|
||||
protected String mUserName;
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@ import java.util.Locale;
|
||||
*/
|
||||
public class GeocoderNominatim {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(GeocoderNominatim.class);
|
||||
static final Logger log = LoggerFactory.getLogger(GeocoderNominatim.class);
|
||||
|
||||
public static final String NOMINATIM_SERVICE_URL = "http://nominatim.openstreetmap.org/";
|
||||
public static final String MAPQUEST_SERVICE_URL = "http://open.mapquestapi.com/nominatim/v1/";
|
||||
|
||||
@@ -23,7 +23,7 @@ import java.util.ArrayList;
|
||||
*/
|
||||
public class NominatimPOIProvider implements POIProvider {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(NominatimPOIProvider.class);
|
||||
static final Logger log = LoggerFactory.getLogger(NominatimPOIProvider.class);
|
||||
|
||||
/* As the doc lacks a lot of features, source code may help:
|
||||
* https://trac.openstreetmap
|
||||
|
||||
@@ -17,7 +17,7 @@ import java.util.List;
|
||||
|
||||
public class OverpassPOIProvider implements POIProvider {
|
||||
|
||||
final static Logger log = LoggerFactory
|
||||
static final Logger log = LoggerFactory
|
||||
.getLogger(OverpassPOIProvider.class);
|
||||
|
||||
public static final String TAG_KEY_WEBSITE = "website".intern();
|
||||
|
||||
@@ -27,7 +27,7 @@ import javax.xml.parsers.SAXParserFactory;
|
||||
*/
|
||||
public class PicasaPOIProvider implements POIProvider {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(PicasaPOIProvider.class);
|
||||
static final Logger log = LoggerFactory.getLogger(PicasaPOIProvider.class);
|
||||
|
||||
String mAccessToken;
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ import java.util.List;
|
||||
* @see OSRMRouteProvider
|
||||
*/
|
||||
public class Route {
|
||||
//final static Logger log = LoggerFactory.getLogger(Route.class);
|
||||
//static final Logger log = LoggerFactory.getLogger(Route.class);
|
||||
|
||||
/**
|
||||
* @see #STATUS_INVALID STATUS_INVALID
|
||||
|
||||
@@ -12,7 +12,7 @@ import java.util.List;
|
||||
* @author M.Kergall
|
||||
*/
|
||||
public class RouteLeg implements Parcelable {
|
||||
//final static Logger log = LoggerFactory.getLogger(RouteLeg.class);
|
||||
//static final Logger log = LoggerFactory.getLogger(RouteLeg.class);
|
||||
|
||||
/**
|
||||
* in km
|
||||
|
||||
@@ -35,7 +35,7 @@ import javax.xml.parsers.SAXParserFactory;
|
||||
*/
|
||||
public class GoogleRouteProvider extends RouteProvider {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(GoogleRouteProvider.class);
|
||||
static final Logger log = LoggerFactory.getLogger(GoogleRouteProvider.class);
|
||||
|
||||
static final String GOOGLE_DIRECTIONS_SERVICE = "http://maps.googleapis.com/maps/api/directions/xml?";
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ import javax.xml.parsers.SAXParserFactory;
|
||||
*/
|
||||
public class MapQuestRouteProvider extends RouteProvider {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(MapQuestRouteProvider.class);
|
||||
static final Logger log = LoggerFactory.getLogger(MapQuestRouteProvider.class);
|
||||
|
||||
static final String MAPQUEST_GUIDANCE_SERVICE = "http://open.mapquestapi.com/guidance/v0/route?";
|
||||
|
||||
|
||||
@@ -30,10 +30,10 @@ import java.util.Locale;
|
||||
*/
|
||||
public class OSRMRouteProvider extends RouteProvider {
|
||||
|
||||
final static Logger log = LoggerFactory.getLogger(OSRMRouteProvider.class);
|
||||
static final Logger log = LoggerFactory.getLogger(OSRMRouteProvider.class);
|
||||
|
||||
// 1 for 6 digit precision, 10 for 5
|
||||
private final static int ENCODING_PRECISION = 1;
|
||||
private static final int ENCODING_PRECISION = 1;
|
||||
|
||||
//static final String OSRM_SERVICE = "http://city.informatik.uni-bremen.de:5000/viaroute?";
|
||||
//static final String OSRM_SERVICE = "http://city.informatik.uni-bremen.de:5001/viaroute?";
|
||||
|
||||
@@ -26,8 +26,8 @@ import okhttp3.Response;
|
||||
* connection.close();</pre>
|
||||
*/
|
||||
public class HttpConnection {
|
||||
private final static int TIMEOUT_CONNECTION = 3000; //ms
|
||||
private final static int TIMEOUT_SOCKET = 10000; //ms
|
||||
private static final int TIMEOUT_CONNECTION = 3000; //ms
|
||||
private static final int TIMEOUT_SOCKET = 10000; //ms
|
||||
|
||||
private static OkHttpClient client;
|
||||
private InputStream stream;
|
||||
|
||||
Reference in New Issue
Block a user