Public Member Functions | Static Public Attributes | Private Attributes | Static Private Attributes
com.github.rosjava.android_apps.application_management.AppManager Class Reference
Inheritance diagram for com.github.rosjava.android_apps.application_management.AppManager:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 AppManager (final String appName, NameResolver resolver)
 AppManager (final String appName)
 AppManager ()
void continuouslyListApps ()
GraphName getDefaultNodeName ()
void listApps ()
void onStart (final ConnectedNode connectedNode)
void setAppListSubscriber (MessageListener< AppList > appListListener)
void setAppName (String appName)
void setFunction (String function)
void setListService (ServiceResponseListener< GetAppListResponse > listServiceResponseListener)
void setStartService (ServiceResponseListener< StartAppResponse > startServiceResponseListener)
void setStopService (ServiceResponseListener< StopAppResponse > stopServiceResponseListener)
void startApp ()
void stopApp ()

Static Public Attributes

static final String PACKAGE = "com.github.rosjava.android_apps.application_management.AppManager"

Private Attributes

MessageListener< AppList > appListListener
String appName
ConnectedNode connectedNode
String function = null
ServiceResponseListener
< GetAppListResponse > 
listServiceResponseListener
NameResolver resolver
ServiceResponseListener
< StartAppResponse > 
startServiceResponseListener
ServiceResponseListener
< StopAppResponse > 
stopServiceResponseListener
Subscriber< AppList > subscriber

Static Private Attributes

static final String listService = "list_apps"
static final String startTopic = "start_app"
static final String stopTopic = "stop_app"

Detailed Description

This class implements the services and topics required to communicate with the robot app manager. Typically to use this class its a three step process:

1) provide a callback via one of the setXXX methods 2) set the function type you want to call (e.g. start_app, platform_info) 3) execute the app manager instance.

INSTANCES MAY ONLY EVER BE EXECUTED ONCE!

Essentially you are creating a node when creating an instance, and rosjava isolates each service/topic to each 'node'.

See the RosAppActivity or RobotActivity (in android_remocons) for examples.

TODO: (DJS) move these into the .rapp_manager module as separate classes. Since these can only be executed once, there is no real advantage to having them together and ultimately just makes it difficult to follow the code.

Definition at line 64 of file AppManager.java.


Constructor & Destructor Documentation

com.github.rosjava.android_apps.application_management.AppManager.AppManager ( final String  appName,
NameResolver  resolver 
) [inline]

Definition at line 83 of file AppManager.java.

Definition at line 88 of file AppManager.java.

Definition at line 92 of file AppManager.java.


Member Function Documentation

Definition at line 123 of file AppManager.java.

Definition at line 182 of file AppManager.java.

Definition at line 164 of file AppManager.java.

void com.github.rosjava.android_apps.application_management.AppManager.onStart ( final ConnectedNode  connectedNode) [inline]

This provides a few ways to create and execute service/topic nodes with an app manager object.

Note - you should only ever call (via NodeMainExecutor.execute() this once! It will fail due to this instance being non-unique in the set of rosjava nodemains for this activity.

Parameters:
connectedNode

Definition at line 195 of file AppManager.java.

void com.github.rosjava.android_apps.application_management.AppManager.setAppListSubscriber ( MessageListener< AppList >  appListListener) [inline]

Definition at line 104 of file AppManager.java.

Definition at line 100 of file AppManager.java.

Definition at line 96 of file AppManager.java.

void com.github.rosjava.android_apps.application_management.AppManager.setListService ( ServiceResponseListener< GetAppListResponse >  listServiceResponseListener) [inline]

Definition at line 118 of file AppManager.java.

void com.github.rosjava.android_apps.application_management.AppManager.setStartService ( ServiceResponseListener< StartAppResponse >  startServiceResponseListener) [inline]

Definition at line 108 of file AppManager.java.

void com.github.rosjava.android_apps.application_management.AppManager.setStopService ( ServiceResponseListener< StopAppResponse >  stopServiceResponseListener) [inline]

Definition at line 113 of file AppManager.java.

Definition at line 128 of file AppManager.java.

Definition at line 146 of file AppManager.java.


Member Data Documentation

Definition at line 77 of file AppManager.java.

Definition at line 72 of file AppManager.java.

Definition at line 80 of file AppManager.java.

Definition at line 81 of file AppManager.java.

Definition at line 70 of file AppManager.java.

Definition at line 76 of file AppManager.java.

final String com.github.rosjava.android_apps.application_management.AppManager.PACKAGE = "com.github.rosjava.android_apps.application_management.AppManager" [static]

Definition at line 67 of file AppManager.java.

Definition at line 73 of file AppManager.java.

Definition at line 74 of file AppManager.java.

Definition at line 68 of file AppManager.java.

Definition at line 75 of file AppManager.java.

Definition at line 69 of file AppManager.java.

Definition at line 78 of file AppManager.java.


The documentation for this class was generated from the following file:


android_apps
Author(s): Daniel Stonier , Kazuto Murase
autogenerated on Fri Aug 28 2015 10:04:40