GoogleMapsExtras
Comment:
- GoogleMapsExtras is an ongoing project to implement more of the Google Maps Android v2 classes in Basic4Android.
BitmapDescriptor
Methods:
BitmapDescriptorFactory
Fields:
- HUE_AZURE As Float
- HUE_BLUE As Float
- HUE_CYAN As Float
- HUE_GREEN As Float
- HUE_MAGENTA As Float
- HUE_ORANGE As Float
- HUE_RED As Float
- HUE_ROSE As Float
- HUE_VIOLET As Float
- HUE_YELLOW As Float
Methods:
- DefaultMarker As BitmapDescriptor
Creates a BitmapDescriptor that refers to the default marker image.
- DefaultMarker2 (Hue As Float) As BitmapDescriptor
Creates a BitmapDescriptor that refers to a colorization of the default marker image.
- FromAsset (AssetName As String) As BitmapDescriptor
Creates a BitmapDescriptor using the name of an image in the assets directory.
- FromBitmap (Bitmap1 As Bitmap) As BitmapDescriptor
Creates a BitmapDescriptor from a given Bitmap.
- FromFile (Filename As String) As BitmapDescriptor
Creates a BitmapDescriptor using the name of an image file located in the internal storage.
- FromPath (AbsolutePath As String) As BitmapDescriptor
Creates a BitmapDescriptor from an absolute file path.
- FromResource (ResourceId As Int) As BitmapDescriptor
Creates a BitmapDescriptor using the resource id of an image.
CameraUpdateFactory
Methods:
- NewCameraPosition (CameraPosition1 As CameraPosition) As CameraUpdate
- NewLatLng (LatLng1 As LatLng) As CameraUpdate
- NewLatLngBounds (LatLngBounds1 As LatLngBounds, Padding As Int) As CameraUpdate
- NewLatLngBounds2 (LatLngBounds1 As LatLngBounds, Width As Int, Height As Int, Padding As Int) As CameraUpdate
- NewLatLngZoom (LatLng1 As LatLng, Zoom As Float) As CameraUpdate
- ScrollBy (XPixel As Float, YPixel As Float) As CameraUpdate
- ZoomBy (Amount As Float, Point1 As Point) As CameraUpdate
- ZoomBy2 (Amount As Float) As CameraUpdate
- ZoomIn As CameraUpdate
- ZoomOut As CameraUpdate
- ZoomTo (ZoomLevel As Float) As CameraUpdate
CancelableCallback
Events:
Methods:
- Initialize (EventName As String)
- IsInitialized As Boolean
Circle
Methods:
- IsInitialized As Boolean
- Remove
Remove the Circle from the map.
Properties:
- Center As LatLngWrapper
Get or Set the Circle center.
- FillColor As Int
Get or Set the Circle fill color.
- Id As String [read only]
Get the Circle Id.
- Radius As Double
Get or Set the Circle radius in meters.
- StrokeColor As Int
Get or Set the Circle stroke color.
- StrokeWidth As Float
Get or Set the Circle stroke width.
- Visible As Boolean
- ZIndex As Float
Get or Set the Circle ZIndex.
CircleOptions
Methods:
- Center (LatLng1 As LatLng) As CircleOptions
Sets the center using a LatLng.
- Center2 (Latitude As Double, Longitude As Double) As CircleOptions
Sets the center using latitude and longitude.
- FillColor (FillColor As Int) As CircleOptions
Sets the fill color.
- GetCenter As LatLngWrapper
Gets the center as a LatLng.
- GetFillColor As Int
Gets the fill color.
- GetRadius As Double
Gets the radius in meters.
- GetStrokeColor As Int
Gets the stroke color.
- GetStrokeWidth As Float
Gets the stroke width.
- GetZIndex As Float
Gets the ZIndex.
- Initialize
Creates a new CircleOptions.
- IsInitialized As Boolean
- IsVisible As Boolean
Gets the visibility of this circle.
- Radius (Radius As Double) As CircleOptions
Sets the radius in meters.
- StrokeColor (StrokeColor As Int) As CircleOptions
Sets the stroke color.
- StrokeWidth (StrokeWidth As Float) As CircleOptions
Sets the stroke width.
- Visible (Visible As Boolean) As CircleOptions
Sets the visibility.
- ZIndex (ZIndex As Float) As CircleOptions
Sets the ZIndex.
CustomLocationSource
Events:
- Activate (OnLocationChangedListener1 As OnLocationChangedListener)
- Deactivate
Methods:
- Initialize (EventName As String)
Initialize the CustomLocationSource.
Raises the events:
Activate(OnLocationChangedListener1 As OnLocationChangedListener)
The CustomLocationSource has been activated.
OnLocationChangedListener1's OnLocationChanged(Location1 As Location) method should be called each time a new Location is available.
Deactivate
The CustomLocationSource has been deactivated.
No further calls to OnLocationChangedListener1's OnLocationChanged(Location1 As Location) method should be made.
- IsInitialized As Boolean
CustomTileProvider
Fields:
Methods:
- Initialize (ClassInstance As Object, SubName As String)
Initialize the CustomTileProvider.
When the CustomTileProvider requires a Tile it uses Reflection to call a b4a Sub, the b4a Sub must return a Tile object.
ClassInstance - The module that contains the Sub that will return a Tile object.
SubName - The name of the Sub that will return a Tile object.
- IsInitialized As Boolean
CustomUrlTileProvider
Events:
- GetTileUrl (TileX As Int, TileY As Int, Zoom As Int))
Methods:
- Initialize (EventName As String, Width As Int, Height As Int)
Initialize the CustomUrlTileProvider.
Width - width of the images used for tiles.
Height - height of the images used for tiles.
The CustomUrlTileProvider raises the event:
GetTileUrl(TileX As Int, TileY As Int, Zoom As Int) As String
- IsInitialized As Boolean
GoogleMapsExtras
Events:
- SnapshotReady (Bitmap1 As Bitmap)
Methods:
- AddCircle (GoogleMap1 As GoogleMap, CircleOptions1 As CircleOptions) As Circle
Adds a circle to the map.
- AddGroundOverlay (GoogleMap1 As GoogleMap, GroundOverlayOptions1 As GroundOverlayOptions) As GroundOverlay
- AddMarker (GoogleMap1 As GoogleMap, MarkerOptions1 As MarkerOptions) As MarkerWrapper
Adds a Marker to the map.
This method uses a MarkerOptions object to create a Marker.
- AddPolygon (GoogleMap1 As GoogleMap, PolygonOptions1 As PolygonOptions) As Polygon
Adds a polygon to the map.
- AddPolyline (GoogleMap1 As GoogleMap, PolylineOptions1 As PolylineOptions) As PolylineWrapper
Adds a polyline to the map.
This method uses a PolylineOptions object to create a Polyline.
- AddTileOverlay (GoogleMap1 As GoogleMap, TileOverlayOptions1 As TileOverlayOptions) As TileOverlay
Adds a tile overlay to the map.
- AnimateCamera (GoogleMap1 As GoogleMap, CameraUpdate1 As CameraUpdate)
Animates the movement of the camera from the current position to the position defined in the CameraUpdate1.
- AnimateCamera2 (GoogleMap1 As GoogleMap, CameraUpdate1 As CameraUpdate, CancelableCallback1 As CancelableCallback)
Animates the movement of the camera from the current position to the position defined in the CameraUpdate1.
Raising the CancelableCallback Cancel or Finish event on termination or completion.
Pass Null as the CancelableCallback if not required.
- AnimateCamera3 (GoogleMap1 As GoogleMap, CameraUpdate1 As CameraUpdate, DurationMs As Int, CancelableCallback1 As CancelableCallback)
Animates the movement of the camera from the current position to the position defined in the CameraUpdate1 over the specified duration.
Raising the CancelableCallback Cancel or Finish event on termination or completion.
Pass Null as the CancelableCallback if not required.
- AnimateToBounds (GoogleMap1 As GoogleMap, LatLngBounds1 As LatLngBounds, Padding As Int)
Adjust and animate the map center and zoom level so that it fully contains the LatLngBounds.
Padding is defined in units of pixels.
This method is deprecated, instead use the CameraUpdateFactory and CameraUpdate objects and the AnimateCamera method.
- AnimateToBounds2 (GoogleMap1 As GoogleMap, LatLngBounds1 As LatLngBounds, Width As Int, Height As Int, Padding As Int)
Adjust and animate the map center and zoom level so that it fully contains the LatLngBounds.
Padding is defined in units of pixels.
Width and Height should define the dimensions of the GoogleMap.
This method is deprecated, instead use the CameraUpdateFactory and CameraUpdate objects and the AnimateCamera method.
- GetMaxZoomLevel (GoogleMap1 As GoogleMap) As Float
Returns the maximum zoom level for the current camera position.
This takes into account what map type is currently being used, e.g., satellite or terrain may have a lower max zoom level than the base map tiles.
- GetMinZoomLevel (GoogleMap1 As GoogleMap) As Float
Returns the minimum zoom level.
This is the same for every location (unlike the maximum zoom level) but may vary between devices and map sizes.
- GetProjection (GoogleMap1 As GoogleMap) As Projection
Returns a Projection object that you can use to convert between screen coordinates and latitude/longitude coordinates.
- IsIndoorEnabled (GoogleMap1 As GoogleMap) As Boolean
Returns whether indoor maps are currently enabled.
- IsTrafficEnabled (GoogleMap1 As GoogleMap) As Boolean
Returns whether the map is drawing traffic data.
- MoveCamera (GoogleMap1 As GoogleMap, CameraUpdate1 As CameraUpdate)
Moves the camera from the current position to the position defined in the CameraUpdate1.
- SetBuildingsEnabled (GoogleMap1 As GoogleMap, Enabled As Boolean)
Turns the 3D buildings layer on or off.
- SetIndoorEnabled (GoogleMap1 As GoogleMap, Enabled As Boolean) As Boolean
Sets whether indoor maps should be enabled.
- SetInfoWindowAdapter (GoogleMap1 As GoogleMap, InfoWindowAdapter1 As InfoWindowAdapter)
Sets a custom renderer for the contents of infowindows.
To unset the custom renderer use Null.
- SetLocationSource (GoogleMap1 As GoogleMap, LocationSource1 As LocationSource)
Replaces the default location source of the MyLocation layer.
Pass Null to restore the default location source.
- SetOnInfoWindowClickListener (GoogleMap1 As GoogleMap, OnInfoWindowClickListener1 As OnInfoWindowClickListener)
Sets a callback that's invoked when an infowindow is clicked.
To unset the callback use Null.
- SetOnMapLoadedCallback (GoogleMap1 As GoogleMap, OnMapLoadedCallback1 As OnMapLoadedCallback)
Sets a callback that's invoked when the map has finished rendering.
- SetOnMarkerDragListener (GoogleMap1 As GoogleMap, OnMarkerDragListener1 As OnMarkerDragListener)
Sets a callback that's invoked when a marker is dragged.
To unset the callback use Null.
- SetOnMyLocationButtonClickListener (GoogleMap1 As GoogleMap, OnMyLocationButtonClickListener As OnMyLocationButtonClickListener)
Sets a callback that's invoked when the my location button is clicked.
If the listener returns true, the event is consumed and the default behavior will not occur.
If it returns false, the default behavior will occur (i.e. The camera moves such that it is centered on the user location).
- SetOnMyLocationChangeListener (GoogleMap1 As GoogleMap, OnMyLocationChangeListener1 As OnMyLocationChangeListener)
Sets a callback that's invoked when the my location dot changes location.
To unset the callback use Null.
- SetPadding (GoogleMap1 As GoogleMap, Left As Int, Top As Int, Right As Int, Bottom As Int)
Sets padding on the map.
This method allows you to define a visible region on the map, to signal to the map that portions of the map around the edges may be obscured, by setting padding on each of the four edges of the map.
Map functions will be adapted to the padding.
For example, the zoom controls, compass, copyright notices and Google logo will be moved to fit inside the defined region, camera movements will be relative to the center of the visible region, etc.
- SetTrafficEnabled (GoogleMap1 As GoogleMap, Enabled As Boolean)
Toggles the traffic layer on or off.
- Snapshot (GoogleMap1 As GoogleMap, EventName As String)
Takes a snapshot of the map.
On completion raises the event SnapshotReady(Bitmap1 As Bitmap).
- StopAnimation (GoogleMap1 As GoogleMap)
Stops the camera animation if there is one in progress.
When the method is called, the camera stops moving immediately and remains in that position.
GroundOverlay
Methods:
- IsInitialized As Boolean
- IsVisible As Boolean
- Remove
- SetDimensions (Width As Float)
- SetDimensions2 (Width As Float, Height As Float)
Properties:
- Bearing As Float
- Bounds As LatLngBounds [read only]
- Height As Float [read only]
- Id As String [read only]
- Image As Bitmap [write only]
Sets the image for the Ground Overlay using a Bitmap.
The new image will occupy the same bounds as the old image.
- Image2 As BitmapDescriptor [write only]
Sets the image for the Ground Overlay using a BitmapDescriptor.
The new image will occupy the same bounds as the old image.
- Position As LatLngWrapper
- PositionFromBounds As LatLngBounds [write only]
- Transparency As Float
- Visible As Boolean [write only]
- Width As Float [read only]
- ZIndex As Float
GroundOverlayOptions
Methods:
- Anchor (U As Float, V As Float) As GroundOverlayOptions
Specifies the anchor to be at a particular point in the image.
- GetBearing As Float
- GetTransparency As Float
- GetZIndex As Float
- Image (Bitmap1 As Bitmap) As GroundOverlayOptions
Specifies the image for this ground overlay using a Bitmap.
- Image2 (BitmapDescriptor1 As BitmapDescriptor) As GroundOverlayOptions
Specifies the image for this ground overlay using a BitmapDescriptor.
- Initialize
- IsInitialized As Boolean
- IsVisible As Boolean
- Position (Position As LatLng, Width As Float, Height As Float) As GroundOverlayOptions
Specifies the position for this ground overlay using an anchor point (a LatLng), width and height (both in meters).
- Position2 (Position As LatLng, Width As Float) As GroundOverlayOptions
Specifies the position for this ground overlay using an anchor point (a LatLng) and the width (in meters).
- PositionFromBounds (Bounds As LatLngBounds) As GroundOverlayOptions
Specifies the position for this ground overlay.
- SetBearing (Bearing As Float) As GroundOverlayOptions
Specifies the bearing of the ground overlay in degrees clockwise from north.
- SetTransparency (Transparency As Float) As GroundOverlayOptions
Specifies the transparency of the ground overlay.
- SetZIndex (ZIndex As Float) As GroundOverlayOptions
Specifies the ground overlay's zIndex, i.e., the order in which it will be drawn.
- Visible (Visible As Boolean) As GroundOverlayOptions
Specifies the visibility for the ground overlay.
Properties:
- AnchorU As Float [read only]
Returns horizontal distance, normalized to [0, 1], of the anchor from the left edge.
- AnchorV As Float [read only]
Returns vertical distance, normalized to [0, 1], of the anchor from the top edge.
- Bounds As LatLngBounds [read only]
- Height As Float [read only]
- Location As LatLngWrapper [read only]
- Width As Float [read only]
InfoWindowAdapter
Events:
- GetInfoContents (Marker1 As Marker))
- GetInfoWindow (Marker1 As Marker))
Methods:
- Initialize (EventName As String)
- IsInitialized As Boolean
LatLngBounds
Methods:
- Contains (LatLng1 As LatLng) As Boolean
Returns whether this LatLngBounds contains LatLng1.
- Including (LatLng1 As LatLng) As LatLngBounds
Returns a new LatLngBounds that extends this LatLngBounds to include the given LatLng.
- Initialize (SouthWest As LatLng, NorthEast As LatLng)
Initialize the LatLngBounds.
- IsInitialized As Boolean
Properties:
- Center As LatLngWrapper [read only]
Returns the center of this LatLngBounds.
The center is simply the average of the coordinates (taking into account if it crosses the antimeridian).
This is approximately the geographical center (it would be exact if the Earth were a perfect sphere).
It will not necessarily be the center of the rectangle as drawn on the map due to the Mercator projection.
- NorthEast As LatLngWrapper [read only]
Returns north-east corner of this LatLngBounds as a LatLng.
- SouthWest As LatLngWrapper [read only]
Returns south-west corner of this LatLngBounds as a LatLng.
LatLngBoundsBuilder
Methods:
- Build As LatLngBounds
Creates and returns the LatLngBounds.
- Include (LatLng1 As LatLng) As LatLngBoundsBuilder
Includes this point for building of the bounds.
The bounds will be extended in a minimum way to include this point.
https://developers.google.com/maps/documentation/android/reference/com/google/android/gms/maps/model/LatLngBounds.Builder
- Initialize
- IsInitialized As Boolean
MarkerExtras
Methods:
- GetAlpha (Marker1 As Marker) As Float
Gets the alpha of the marker.
- GetId (Marker1 As Marker) As String
Gets Marker1's Id.
- GetRotation (Marker1 As Marker) As Float
Gets the rotation of the Marker in degrees clockwise about the Marker's anchor point.
- IsFlat (Marker1 As Marker) As Boolean
Gets the flat setting for this Marker.
- SetAlpha (Marker1 As Marker, Alpha As Float)
Sets the alpha (opacity) of Marker1.
This is a value from 0 to 1, where 0 means the marker is completely transparent and 1 means the marker is completely opaque.
- SetAnchor (Marker1 As Marker, U As Float, V As Float)
Specifies the anchor to be at a particular point in the marker image.
- SetFlat (Marker1 As Marker, Flat As Boolean)
Sets whether this Marker should be flat against the map (True) or a billboard facing the camera (False).
- SetInfoWindowAnchor (Marker1 As Marker, U As Float, V As Float)
Specifies the point in the marker image at which to anchor the info window when it is displayed.
- SetRotation (Marker1 As Marker, Rotation As Float)
Sets the rotation of the marker in degrees clockwise about the marker's anchor point.
The axis of rotation is perpendicular to the marker.
A rotation of 0 corresponds to the default position of the marker.
MarkerOptions
Methods:
- Alpha (Alpha As Float) As MarkerOptions
Sets the alpha (opacity) of the marker.
This is a value from 0 to 1, where 0 means the marker is completely transparent and 1 means the marker is completely opaque.
- Anchor (U As Float, V As Float) As MarkerOptions
Specifies the anchor to be at a particular point in the marker image.
- Draggable (Draggable As Boolean) As MarkerOptions
Sets the draggability for the marker.
- Flat (Flat As Boolean) As MarkerOptions
Sets whether this Marker should be flat against the map (True) or a billboard facing the camera (False).
- GetAlpha As Float
Gets the alpha that has been set for this MarkerOptions object.
- GetAnchorU As Float
Horizontal distance, normalized to [0, 1], of the anchor from the left edge.
- GetAnchorV As Float
Vertical distance, normalized to [0, 1], of the anchor from the top edge.
- GetIcon As BitmapDescriptor
Gets the custom icon set for this MarkerOptions object.
- GetInfoWindowAnchorU As Float
- GetInfoWindowAnchorV As Float
- GetPosition As LatLngWrapper
Returns the position set for this MarkerOptions object.
- GetRotation As Float
Gets the rotation set for this MarkerOptions.
- GetSnippet As String
Gets the snippet set for this MarkerOptions object.
- GetTitle As String
Gets the title set for this MarkerOptions object.
- Icon (BitmapDescriptor1 As BitmapDescriptor) As MarkerOptions
Sets the icon for the marker.
- InfoWindowAnchor (U As Float, V As Float) As MarkerOptions
Specifies the anchor point of the info window on the marker image.
The default is the top middle of the image.
U - coordinate of the info window anchor, as a ratio of the image width (in the range [0, 1]).
V - coordinate of the info window anchor, as a ratio of the image height (in the range [0, 1]).
- Initialize
Creates a new set of MarkerOptions.
- IsDraggable As Boolean
Gets the draggability setting for this MarkerOptions object.
- IsFlat As Boolean
Gets the flat setting for this MarkerOptions object.
- IsInitialized As Boolean
- IsVisible As Boolean
Gets the visibility setting for this MarkerOptions object.
- Position (LatLng1 As LatLng) As MarkerOptions
Sets the location for the marker using a LatLng.
- Position2 (Latitude As Double, Longitude As Double) As MarkerOptions
Sets the location for the marker using latitude and longitude values.
- Rotate (Rotation As Float) As MarkerOptions
- Snippet (Snippet As String) As MarkerOptions
Sets the snippet for the marker.
- Title (Title As String) As MarkerOptions
Sets the title for the marker.
- Visible (Visible As Boolean) As MarkerOptions
Sets the visibility for the marker.
OnInfoWindowClickListener
Events:
- Click (Marker1 As Marker)
Methods:
- Initialize (EventName As String)
Initialize the OnInfoWindowClickListener.
- IsInitialized As Boolean
OnLocationChangedListener
Methods:
- IsInitialized As Boolean
- OnLocationChanged (Location1 As Location)
Passes a Location to the CustomLocationSource.
The Location must be initialized and not null.
OnMapLoadedCallback
Events:
Methods:
- Initialize (EventName As String)
Initialize the OnMapLoadedCallback object.
The MapLoaded event will be raised when the map has finished rendering.
This occurs after all tiles required to render the map have been fetched, and all labelling is complete.
This event will not be raised if the map never loads due to connectivity issues,
or if the map is continuously changing and never completes loading due to the user constantly interacting with the map.
This event will only be raised once. You must request another callback if you want to be notified again.
- IsInitialized As Boolean
OnMarkerDragListener
Events:
- Drag (Marker1 As Marker)
- DragEnd (Marker1 As Marker)
- DragStart (Marker1 As Marker)
Methods:
- Initialize (EventName As String)
Initialize the OnMarkerDragListener.
- IsInitialized As Boolean
OnMyLocationButtonClickListener
Events:
- MyLocationButtonClick As Boolean
Methods:
- Initialize (EventName As String)
- IsInitialized As Boolean
OnMyLocationChangeListener
Events:
- MyLocationChange (Location1 As Location)
Methods:
- Initialize (EventName As String)
- IsInitialized As Boolean
Point
Methods:
- Initialize (X As Int, Y As Int)
- IsInitialized As Boolean
- Negate
Negate the point's coordinates.
- Offset (Dx As Int, Dy As Int)
Offset the point's coordinates by Dx, Dy.
- Set (X As Int, Y As Int)
Set the point's X and Y coordinates .
Properties:
- X As Int [read only]
- Y As Int [read only]
Polygon
Methods:
- IsInitialized As Boolean
- Remove
Remove this polygon from the map.
Properties:
- FillColor As Int
Get or Set the fill color of this polygon.
- Geodesic As Boolean
Get or Set whether the line segments are geodesic lines (shortest path on the earth surface) or straight lines.
The default value is False.
- Holes As List
Get or Set the holes of this polygon.
Setting this property will take a copy of the holes, so further mutations to holes will have no effect on this polygon.
Holes should be set using a List that contains a List of LatLng objects for each hole.
- Points As List
Get or Set the list of points that build the polyline.
To Add vertices to the outline of the polygon being built, the vertices must be added in counterclockwise order.
The list should hold objects of type LatLng.
- StrokeColor As Int
Get or Set the stroke color of this polygon.
- StrokeWidth As Float
Get or Set the stroke width of this polygon.
- Visible As Boolean
Get or Set the visibility of this polygon.
- ZIndex As Float
Get or Set the ZIndex of this polygon.
PolygonOptions
Methods:
- AddHole (Hole As List)
Adds a hole to the polygon being built.
The vertices of the hole must be in counterclockwise order.
Hole should be a List of LatLng objects.
- AddPoint (LatLng1 As LatLng)
Adds a vertex to the outline of the polygon being built.
- AddPoints (LatLngs As List)
Adds vertices to the outline of the polygon being built. The vertices must be added in counterclockwise order.
The List should hold objects of type LatLng.
- Initialize
- IsInitialized As Boolean
Properties:
- FillColor As Int
- Geodesic As Boolean
- Holes As List [read only]
Get the holes of this polygon.
Returns a List that contains a List of LatLng objects for each hole.
- Points As List [read only]
- StrokeColor As Int
- StrokeWidth As Float
- Visible As Boolean
- ZIndex As Float
PolylineOptions
Methods:
- Add (LatLng1 As LatLng) As PolylineOptions
Adds a vertex to the end of the polyline being built.
- AddPoints (LatLngs As List) As PolylineOptions
Adds vertices to the end of the polyline being built.
The List should hold objects of type LatLng.
- Initialize
- IsInitialized As Boolean
Properties:
- Color As Int
Get or Set the color set for this polyline.
- Geodesic As Boolean
Get or Set whether to draw each segment of this polyline as a geodesic.
- Points As List [read only]
Get a list of LatLngs that make up the path of this polyline.
- Visible As Boolean
Get or Set the visibility of this polyline.
- Width As Float
Get or Set the width of this polyline.
- ZIndex As Float
Get or Set the zIndex of this polyline.
The zIndex determines the order of drawing on the map.
Projection
Methods:
- FromScreenLocation (Point1 As Point) As LatLngWrapper
Returns the geographic location that corresponds to a screen location.
- GetVisibleRegion As VisibleRegion
Gets a projection of the viewing frustum for converting between screen coordinates and geo-latitude/longitude coordinates.
- IsInitialized As Boolean
- ToScreenLocation (LatLng1 As LatLng) As Point
Returns a screen location that corresponds to a geographical coordinate.
StreetViewPanorama
Events:
- PanoramaCameraChange (StreetViewPanoramaCamera1 As StreetViewPanoramaCamera)
- PanoramaChange (StreetViewPanoramaLocation1 As StreetViewPanoramaLocation)
- PanoramaClick (StreetViewPanoramaOrientation1 As StreetViewPanoramaOrientation)
Methods:
- AnimateTo (StreetViewPanorama1 As StreetViewPanoramaCamera, Duration As Long)
Changes the current camera position, orientation and zoom, to a given position over a specified duration.
- GetLocation As StreetViewPanoramaLocation
Returns the current location of the user and information regarding the current panorama's adjacent panoramas.
- GetPanoramaCamera As StreetViewPanoramaCamera
Returns the current orientation and zoom.
- IsInitialized As Boolean
- IsPanningGesturesEnabled As Boolean
Returns whether or not the panning gestures are enabled for the user.
- IsStreetNamesEnabled As Boolean
Returns whether or not the street names appear on the panorama.
- IsUserNavigationEnabled As Boolean
Returns whether or not the navigation is enabled for the user.
- IsZoomGesturesEnabled As Boolean
Returns whether or not the zoom gestures are enabled for the user.
- OrientationToPoint (StreetViewPanoramaOrientation1 As StreetViewPanoramaOrientation) As Point
Returns a screen location that corresponds to an orientation (StreetViewPanoramaOrientation).
- PointToOrientation (Point1 As Point) As StreetViewPanoramaOrientation
Returns the orientation that corresponds to a screen location.
- SetPanningGesturesEnabled (Enabled As Boolean)
Sets whether the user is able to use panning gestures.
- SetPanoramaCameraChangeListener (EventName As String)
Set a PanoramaCameraChangeListener.
Raises the event: PanoramaCameraChange(StreetViewPanoramaCamera1 As StreetViewPanoramaCamera).
Raised when the user makes changes to the camera on the panorama or if the camera is changed programmatically.
Pass empty string as EventName to clear any existing listener.
- SetPanoramaChangeListener (EventName As String)
Set a PanoramaChangeListener.
Raises the event: PanoramaChange(StreetViewPanoramaLocation1 As StreetViewPanoramaLocation).
Pass empty string as EventName to clear any existing listener.
- SetPanoramaClickListener (EventName As String)
Set a PanoramaClickListener.
Raises the event: PanoramaClick(StreetViewPanoramaOrientation1 As StreetViewPanoramaOrientation).
Raised when the user makes a tap gesture on the panorama, but only if none of the overlays of the map handled the gesture.
Pass empty string as EventName to clear any existing listener.
- SetPosition (LatLng1 As LatLng)
Sets the StreetViewPanorama to a given location.
- SetPosition2 (LatLng1 As LatLng, Radius As Int)
Sets the StreetViewPanorama to a given location.
Radius - Defines the area (specified in meters) in which to search for a panorama, centered on the given latitude and longitude.
- SetPosition3 (PanoId As String)
Sets the StreetViewPanorama to a given location.
PanoId - Panorama id of the desired location.
- SetStreetNamesEnabled (Enabled As Boolean)
Sets whether the user is able to see street names on panoramas.
- SetUserNavigationEnabled (Enabled As Boolean)
Sets whether the user is able to move to another panorama.
- SetZoomGesturesEnabled (Enabled As Boolean)
Sets whether the user is able to use zoom gestures.
StreetViewPanoramaCamera
Methods:
- Builder As StreetViewPanoramaCameraBuilder
Creates a builder for a Street View panorama camera.
- Builder2 (StreetViewPanoramaCamera1 As StreetViewPanoramaCamera) As StreetViewPanoramaCameraBuilder
Creates a builder for a Street View panorama camera.
- GetOrientation As StreetViewPanoramaOrientation
Returns the particular camera's tilt and bearing as an orientation.
- Initialize (Zoom As Float, Tilt As Float, Bearing As Float)
Constructs a StreetViewPanoramaCamera.
- IsInitialized As Boolean
StreetViewPanoramaCameraBuilder
Methods:
- Bearing (Bearing As Float) As StreetViewPanoramaCameraBuilder
Sets the direction that the camera is pointing in, in degrees clockwise from north.
- Build As StreetViewPanoramaCamera
Builds a StreetViewPanoramaCamera.
- IsInitialized As Boolean
- Orientation (StreetViewPanoramaOrientation1 As StreetViewPanoramaOrientation) As StreetViewPanoramaCameraBuilder
Sets the camera tilt and bearing based upon the given orientation's tilt and bearing.
- Tilt (Tilt As Float) As StreetViewPanoramaCameraBuilder
Sets the angle, in degrees, of the camera from the horizon of the panorama.
- Zoom (Zoom As Float) As StreetViewPanoramaCameraBuilder
Sets the zoom level of the camera.
StreetViewPanoramaLink
Methods:
Properties:
- Bearing As Float [read only]
The direction of the linked Street View panorama, in degrees clockwise from north
- PanoId As String [read only]
Panorama ID of the linked Street View panorama.
StreetViewPanoramaLocation
Methods:
Properties:
- Links() As StreetViewPanoramaLink [read only]
Array of StreetViewPanoramaLink able to be reached from the current position.
- PanoId As String [read only]
The panorama ID of the current Street View panorama.
- Position As LatLngWrapper [read only]
The location of the current Street View panorama.
StreetViewPanoramaOptions
Methods:
- Initialize
- IsInitialized As Boolean
- SetPanningGesturesEnabled (Enabled As Boolean) As StreetViewPanoramaOptions
Toggles the ability for users to use pan around on panoramas using gestures.
- SetPanoramaCamera (StreetViewPanoramaCamera1 As StreetViewPanoramaCamera) As StreetViewPanoramaOptions
Specifies the initial camera for the Street View panorama.
- SetPanoramaId (PanoramaId As String) As StreetViewPanoramaOptions
Specifies the initial position for the Street View panorama based on a panorama id.
- SetPosition (LatLng1 As LatLng) As StreetViewPanoramaOptions
Specifies the initial position for the Street View panorama based upon location.
- SetPosition2 (LatLng1 As LatLng, Radius As Integer) As StreetViewPanoramaOptions
Specifies the initial position for the Street View panorama based upon location and radius.
- SetStreetNamesEnabled (Enabled As Boolean) As StreetViewPanoramaOptions
Toggles the ability for users to see street names on panoramas.
- SetUserNavigationEnabled (Enabled As Boolean) As StreetViewPanoramaOptions
Toggles the ability for users to move between panoramas.
- SetZoomGesturesEnabled (Enabled As Boolean) As StreetViewPanoramaOptions
Toggles the ability for users to zoom on panoramas using gestures.
Properties:
- PanningGesturesEnabled As Boolean [read only]
- PanoramaId As String [read only]
- Position As LatLngWrapper [read only]
- Radius As Int [read only]
- StreetNamesEnabled As Boolean [read only]
- StreetViewPanoramaCamera As StreetViewPanoramaCamera [read only]
- UserNavigationEnabled As Boolean [read only]
- ZoomGesturesEnabled As Boolean [read only]
StreetViewPanoramaOrientation
Methods:
- Builder As StreetViewPanoramaOrientationBuilder
Creates a builder for a Street View panorama orientation.
- Builder2 (StreetViewPanoramaOrientation1 As StreetViewPanoramaOrientation) As StreetViewPanoramaOrientationBuilder
Creates a builder for a Street View panorama orientation.
- Initialize (Tilt As Float, Bearing As Float)
- IsInitialized As Boolean
Properties:
- Bearing As Float [read only]
Direction of the orientation, in degrees clockwise from north.
- Tilt As Float [read only]
The angle, in degrees, of the orientation.
StreetViewPanoramaOrientationBuilder
Methods:
- Build As StreetViewPanoramaOrientation
Builds a StreetViewPanoramaOrientation.
- IsInitialized As Boolean
- SetBearing (Bearing As Float) As StreetViewPanoramaOrientationBuilder
Sets the direction of the orientation, in degrees clockwise from north.
- SetTilt (Tilt As Float) As StreetViewPanoramaOrientationBuilder
Sets the angle, in degrees, of the orientation This value is restricted to being between -90 (directly down) and 90 (directly up).
Properties:
- Bearing As Float [read only]
Direction of the orientation, in degrees clockwise from north.
- Tilt As Float [read only]
The angle, in degrees, of the orientation.
StreetViewPanoramaView
Methods:
- BringToFront
- GetStreetViewPanorama As StreetViewPanorama
Gets the underlying StreetViewPanorama that is tied to this view.
- Initialize
- Initialize2 (StreetViewPanoramaOptions1 As StreetViewPanoramaOptions)
- Invalidate
- Invalidate2 (arg0 As Rect)
- Invalidate3 (arg0 As Int, arg1 As Int, arg2 As Int, arg3 As Int)
- IsInitialized As Boolean
- OnCreate (Bundle1 As Bundle)
- OnDestroy
- OnLowMemory
- OnPause
- OnResume
- OnSaveInstanceState (Bundle1 As Bundle)
- RemoveView
- RequestFocus As Boolean
- SendToBack
- SetBackgroundImage (arg0 As Bitmap)
- SetColorAnimated (arg0 As Int, arg1 As Int, arg2 As Int)
- SetLayout (arg0 As Int, arg1 As Int, arg2 As Int, arg3 As Int)
- SetLayoutAnimated (arg0 As Int, arg1 As Int, arg2 As Int, arg3 As Int, arg4 As Int)
- SetVisibleAnimated (arg0 As Int, arg1 As Boolean)
Properties:
- Background As Drawable
- Color As Int [write only]
- Enabled As Boolean
- Height As Int
- Left As Int
- Tag As Object
- Top As Int
- Visible As Boolean
- Width As Int
StreetViewPanoramaViewActivity
Methods:
- Initialize
- IsInitialized As Boolean
- RegisterStreetViewPanoramaViewCallbacks (StreetViewPanoramaView1 As StreetViewPanoramaView)
Registers this Activity as the handler for the lifecycle callbacks of StreetViewPanoramaView1.
- UnregisterStreetViewPanoramaViewCallbacks (StreetViewPanoramaView1 As StreetViewPanoramaView)
Unregisters this Activity as the handler for the lifecycle callbacks of StreetViewPanoramaView1.
Tile
Methods:
- Initialize (Width As Int, Height As Int, Data() As Byte)
- IsInitialized As Boolean
TileOverlay
Methods:
- ClearTileCache
Clears the tile cache so that all tiles will be requested again from the TileProvider.
- IsInitialized As Boolean
- IsVisible As Boolean
Gets the visibility of this tile overlay.
- Remove
Removes this tile overlay from the map.
Properties:
- FadeIn As Boolean
Get or Set whether the tiles should fade in.
Default value is True.
- Id As String [read only]
Returns this tile overlay's id.
- Visible As Boolean [write only]
Sets the visibility of this tile overlay.
- ZIndex As Float
Get or Set the zIndex of this tile overlay.
TileOverlayOptions
Methods:
- GetFadeIn As Boolean
- GetZIndex As Float
- Initialize
Initializes a new set of tile overlay options.
- IsInitialized As Boolean
- IsVisible As Boolean
Returns the visibility setting for this TileOverlayOptions object.
- SetFadeIn (FadeIn As Boolean) As TileOverlayOptions
Set whether the tiles should fade in.
Default value is True.
- SetTileProvider (TileProvider1 As TileProvider) As TileOverlayOptions
Specifies the tile provider to use for this tile overlay.
- SetVisible (Visible As Boolean) As TileOverlayOptions
- SetZIndex (ZIndex As Float) As TileOverlayOptions
UrlTileProvider
Methods:
- Initialize (UrlTemplate As String, Width As Int, Height As Int)
Initialize the UrlTileProvider.
UrlTemplate - a String which is the Url to a tile with X, Y and zoom parameters replaced:
Here the standard OSM slippy map tilenaming is used.
http:///%3$d/%1$d/%2$d.png
Url parameters are %1$d tileX, %2$d tileY, %3$d zoom
Width - tile width in pixels.
Height - tile height in pixels.
- IsInitialized As Boolean
VisibleRegion
Methods:
- Initialize (NearLeft As LatLng, NearRight As LatLng, FarLeft As LatLng, FarRight As LatLng, LatLngBounds1 As LatLngBounds)
Creates a new VisibleRegion given the four corners of the camera.
- IsInitialized As Boolean
Properties:
- FarLeft As LatLngWrapper [read only]
- FarRight As LatLngWrapper [read only]
- LatLngBounds As LatLngBounds [read only]
- NearLeft As LatLngWrapper [read only]
- NearRight As LatLngWrapper [read only]