public abstract class MapActivity extends MetricFragmentActivity
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
TAG |
Constructor and Description |
---|
MapActivity() |
Modifier and Type | Method and Description |
---|---|
boolean |
dispatchKeyEvent(android.view.KeyEvent event) |
void |
executeOnActive(java.lang.Runnable task)
Run a task only when the activity is started (active state) or enqueue
it to be run when the activity is started.
|
MapAssets |
getMapAssets() |
MapComponent |
getMapComponent(java.lang.Class<? extends MapComponent> clazz)
Given a class, find the instance of a specific map component.
|
MapComponent |
getMapComponent(java.lang.String className)
Based on the classname string, return the appropriate class.
|
abstract MapView |
getMapView()
Should return the MapView from the client defined layout
|
boolean |
isActive() |
protected void |
loadAssets() |
void |
loadListeners(java.lang.String eventType,
java.lang.String actionUriStr,
ConfigEnvironment config) |
protected void |
loadRequiredAssets() |
void |
onConfigurationChanged(android.content.res.Configuration newConfig) |
void |
onCreate(android.os.Bundle savedInstanceState) |
protected void |
onDestroy() |
boolean |
onGenericMotionEvent(android.view.MotionEvent event) |
void |
onLowMemory() |
protected void |
onPause() |
protected void |
onResume() |
void |
onStart() |
void |
onStop() |
boolean |
onTouchEvent(android.view.MotionEvent event) |
void |
postOnActive(java.lang.Runnable task)
Post a task only when the activity is started (active state) or enqueue
it to be run when the activity is started.
|
void |
registerMapComponent(MapComponent observer)
Add a MapComponent to the mapping engine.
|
void |
unregisterMapComponent(MapComponent observer)
Remove a MapComponent from the mapping enging
|
dispatchTouchEvent
public static final java.lang.String TAG
public void onCreate(android.os.Bundle savedInstanceState)
onCreate
in class MetricFragmentActivity
public MapAssets getMapAssets()
protected void onDestroy()
onDestroy
in class MetricFragmentActivity
public void onStart()
onStart
in class MetricFragmentActivity
public void onStop()
onStop
in class MetricFragmentActivity
protected void onPause()
onPause
in class MetricFragmentActivity
protected void onResume()
onResume
in class MetricFragmentActivity
public void onConfigurationChanged(android.content.res.Configuration newConfig)
public boolean isActive()
public boolean onTouchEvent(android.view.MotionEvent event)
public boolean onGenericMotionEvent(android.view.MotionEvent event)
public boolean dispatchKeyEvent(android.view.KeyEvent event)
dispatchKeyEvent
in class MetricFragmentActivity
public void onLowMemory()
public void registerMapComponent(MapComponent observer)
observer
- the MapComponentMapComponent
public void unregisterMapComponent(MapComponent observer)
observer
- the map component to removepublic MapComponent getMapComponent(java.lang.Class<? extends MapComponent> clazz)
clazz
- the class file to find.public MapComponent getMapComponent(java.lang.String className)
className
- the stringified class anmeprotected void loadRequiredAssets()
protected void loadAssets() throws java.io.IOException, org.xml.sax.SAXException
java.io.IOException
org.xml.sax.SAXException
public void loadListeners(java.lang.String eventType, java.lang.String actionUriStr, ConfigEnvironment config) throws java.io.IOException, org.xml.sax.SAXException
java.io.IOException
org.xml.sax.SAXException
public abstract MapView getMapView()
public void executeOnActive(java.lang.Runnable task)
task
- Task to run if the activity is active (ie onStart has been called).public void postOnActive(java.lang.Runnable task)
task
- Task to run if the activity is active (ie onStart has been called).