What is the purpose of the .launch file in the AndroidPocketSphinx project?

579 views Asked by At

So I downloaded the AndroidPocketSphinx project from https://github.com/mistrykajal16/AndroidPocketSphinx built, exported and ran the TestPocketSphinxAndAndroidASR activity as an app.

I wanted to launch the smaller PocketSphinxAndroidDemo activity instead so I found the file PocketSphinxAndroidDemo.launch in the project's root folder and (in Eclipse) I right-clicked it, selected Run As and tried to run it.

Instead of seeing it run I received the following error message:

enter image description here

"Resource '/PocketSphinxAndroidDemo' does not exist".

And my question is why?

What is the purpose of the .launch file in the AndroidPocketSphinx project, if it is not meant to work out of the box?

The content of that file, by the way, is really small:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="com.android.ide.eclipse.adt.debug.LaunchConfigType">
  <intAttribute key="com.android.ide.eclipse.adt.action" value="1"/>
  <stringAttribute key="com.android.ide.eclipse.adt.activity" value="ca.ilanguage.labs.pocketsphinx.ui.PocketSphinxAndroidDemo"/>
  <stringAttribute key="com.android.ide.eclipse.adt.avd" value="TeamTalk"/>
  <stringAttribute key="com.android.ide.eclipse.adt.commandline" value=""/>
  <intAttribute key="com.android.ide.eclipse.adt.delay" value="0"/>
  <booleanAttribute key="com.android.ide.eclipse.adt.nobootanim" value="false"/>
  <intAttribute key="com.android.ide.eclipse.adt.speed" value="0"/>
  <booleanAttribute key="com.android.ide.eclipse.adt.target" value="false"/>
  <booleanAttribute key="com.android.ide.eclipse.adt.wipedata" value="false"/>
  <listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
    <listEntry value="/PocketSphinxAndroidDemo"/>
    <listEntry value="/PocketSphinxAndroidDemo/AndroidManifest.xml"/>
  </listAttribute>
  <listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
    <listEntry value="4"/>
    <listEntry value="1"/>
  </listAttribute>
  <booleanAttribute key="org.eclipse.jdt.launching.ALLOW_TERMINATE" value="true"/>
  <stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="PocketSphinxAndroidDemo"/>
</launchConfiguration>
1

There are 1 answers

1
E-Riz On BEST ANSWER

A .launch file is just the storage of a Launch Configuration, it's not really meant to be looked at or manipulated directly by users. Instead, you look for and edit Launch Configurations via the dedicated dialog, invoked by the Run menu or the toolbar buttons (Run configurations and Debug configurations both reflect launch configs, but one launches the JVM in debug mode).

If you want to duplicate an existing launch, use the Debug Configurations or Run Configurations menu item to open the dialog and there you can select and copy one.