The main classes in the map package and the positioning System Package

Source: Internet
Author: User
Tags reverse geocoding

Main classes in the map package:

Mapcontroller: Main control map Movement, telescopic, with a GPS coordinates as the center, control the view components in the Mapview, management overlay, provide the basic function of the view. Use multiple map modes (map mode (some cities can update traffic in real time), satellite mode, Street View mode) to see Google Maps. Common methods: Animateto (GeoPoint point) setcenter (GeoPoint point) setzoom (int zoomlevel) and so on.

Mapview: Is the view used to display the map, which derives from Android.view.ViewGroup. When Mapview gets the focus, you can control the movement and scaling of the map. Maps can be displayed in different forms, such as Street View mode, satellite mode, etc., via the Setsatellite (Boolean) Settraffic (Boolean), Setstreetview (Boolean) method.

Overlay: is covering to the top of Mapview, you can extend its OnDraw interface, customize the display of something in Mapview. Mapview management of Overlay through Mapview.getoverlays ().

The conversion of GPS coordinates to device coordinates (Geopoint and point) in Projection:mapview.

Locate the main class in the System package:

Locationmanager: This class provides access to location services and provides the ability to get the best location providers. In addition, the proximity alert feature can be implemented with this class.

Locationprovider: This class is an abstract class for locating providers. The location provider has the ability to periodically report the location of the device.

Locationlistener: Provides a callback function when the location information changes. Listener objects must be registered in the location manager beforehand.

Criteria: This class allows the application to select the appropriate location provider by the properties set in the Locationprovider.

Geocoder: A class for working with geocoding and reverse geocoding. Geocoding refers to the conversion of addresses or other descriptions into longitude and latitude, while reverse geocoding translates longitude and latitude into addresses or description languages, which contain two constructors that require the coordinates of longitude and latitude to be passed in. The Getfromlocation method can get a set of arrays of addresses.

The main classes in the map package and the positioning System Package

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.