Search in sources :

Example 31 with LatLng

use of com.google.android.libraries.maps.model.LatLng in project android-places-demos by googlemaps.

the class StringUtil method convertToLatLngBounds.

@Nullable
static LatLngBounds convertToLatLngBounds(@Nullable String southWest, @Nullable String northEast) {
    LatLng soundWestLatLng = convertToLatLng(southWest);
    LatLng northEastLatLng = convertToLatLng(northEast);
    if (soundWestLatLng == null || northEast == null) {
        return null;
    }
    return new LatLngBounds(soundWestLatLng, northEastLatLng);
}
Also used : LatLngBounds(com.google.android.libraries.maps.model.LatLngBounds) LatLng(com.google.android.libraries.maps.model.LatLng) Nullable(androidx.annotation.Nullable)

Aggregations

LatLng (com.google.android.libraries.maps.model.LatLng)31 JSONException (org.json.JSONException)8 MarkerOptions (com.google.android.libraries.maps.model.MarkerOptions)7 PluginMethod (com.getcapacitor.PluginMethod)5 PolylineOptions (com.google.android.libraries.maps.model.PolylineOptions)5 MyItem (com.google.maps.android.utils.demo.model.MyItem)5 InputStream (java.io.InputStream)5 JSONObject (org.json.JSONObject)5 PolygonOptions (com.google.android.libraries.maps.model.PolygonOptions)4 Nullable (androidx.annotation.Nullable)3 GoogleMap (com.google.android.libraries.maps.GoogleMap)3 ArrayList (java.util.ArrayList)3 List (java.util.List)3 JSONArray (org.json.JSONArray)3 DisplayMetrics (android.util.DisplayMetrics)2 Log (android.util.Log)2 View (android.view.View)2 CircleOptions (com.google.android.libraries.maps.model.CircleOptions)2 LatLngBounds (com.google.android.libraries.maps.model.LatLngBounds)2 Marker (com.google.android.libraries.maps.model.Marker)2