DJI Mobile SDK Documentation

class DJIMapView

class DJIMapView extends FrameLayout
Package:com.dji.mapkit.core.maps
Inherits From:FrameLayout
Description:

A View that contains a DJIMapViewInternal and initializes it based on the given defaultProvider attribute. If no attribute is given, the provider will be AMaps. All the life cycle methods must be forwarded from the Activity or Fragment containing this view to the corresponding ones in this class. In particular, the following methods must be forwarded:

Class Members:
method
method onCreate
void onCreate(Bundle savedInstanceState)
Package:com.dji.mapkit.core.maps
Description:

Must be called from the parent Activity/Fragment's corresponding method.

Input Parameters:
Bundle savedInstanceStateBundle which contains the saved instance state.
method
method onStart
void onStart()
Package:com.dji.mapkit.core.maps
Description:

Must be called from the parent Activity/Fragment's corresponding method.

method
method onResume
void onResume()
Package:com.dji.mapkit.core.maps
Description:

Must be called from the parent Activity/Fragment's corresponding method.

method
method onPause
void onPause()
Package:com.dji.mapkit.core.maps
Description:

Must be called from the parent Activity/Fragment's corresponding method.

method
method onStop
void onStop()
Package:com.dji.mapkit.core.maps
Description:

Must be called from the parent Activity/Fragment's corresponding method.

method
method onDestroy
void onDestroy()
Package:com.dji.mapkit.core.maps
Description:

Must be called from the parent Activity/Fragment's corresponding method.

method onSaveInstanceState
void onSaveInstanceState(Bundle outState)
Package:com.dji.mapkit.core.maps
Description:

Must be called from the parent Activity/Fragment's corresponding method.

Input Parameters:
Bundle outStateBundle in which to place your saved state.
method onLowMemory
void onLowMemory()
Package:com.dji.mapkit.core.maps
Description:

Must be called from the parent Activity/Fragment's corresponding method.

method getDJIMapAsync
void getDJIMapAsync(@NonNull final OnDJIMapReadyCallback callback)
Package:com.dji.mapkit.core.maps
Description:

Initializes the map view.

Input Parameters:
@NonNull final OnDJIMapReadyCallback callbackThe callback that will be invoked when the map is ready to be used.