development
Revision | e71a4a39a457e5fc8feb504279c0ea78a7f0122b (tree) |
---|---|
Time | 2009-03-27 05:53:00 |
Author | Raphael Moll <> |
Commiter | The Android Open Source Project |
Automated import from //branches/cupcake/...@142978,142978
@@ -32,8 +32,14 @@ public class AndroidLaunchConfiguration { | ||
32 | 32 | */ |
33 | 33 | public int mLaunchAction = LaunchConfigDelegate.DEFAULT_LAUNCH_ACTION; |
34 | 34 | |
35 | + /** | |
36 | + * Target selection mode for the configuration: either {@link #AUTO} or {@link #MANUAL}. | |
37 | + */ | |
35 | 38 | public enum TargetMode { |
36 | - AUTO(true), MANUAL(false); | |
39 | + /** Automatic target selection mode. */ | |
40 | + AUTO(true), | |
41 | + /** Manual target selection mode. */ | |
42 | + MANUAL(false); | |
37 | 43 | |
38 | 44 | private boolean mValue; |
39 | 45 |
@@ -58,10 +64,7 @@ public class AndroidLaunchConfiguration { | ||
58 | 64 | |
59 | 65 | /** |
60 | 66 | * Target selection mode. |
61 | - * <ul> | |
62 | - * <li><code>true</code>: automatic mode, see {@link #AUTO_TARGET_MODE}</li> | |
63 | - * <li><code>false</code>: manual mode</li> | |
64 | - * </ul> | |
67 | + * @see TargetMode | |
65 | 68 | */ |
66 | 69 | public TargetMode mTargetMode = LaunchConfigDelegate.DEFAULT_TARGET_MODE; |
67 | 70 |
@@ -17,9 +17,6 @@ | ||
17 | 17 | package com.android.ide.eclipse.adt.launch; |
18 | 18 | |
19 | 19 | import com.android.ddmlib.AndroidDebugBridge; |
20 | -import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener; | |
21 | -import com.android.ddmlib.AndroidDebugBridge.IDebugBridgeChangeListener; | |
22 | -import com.android.ddmlib.AndroidDebugBridge.IDeviceChangeListener; | |
23 | 20 | import com.android.ddmlib.Client; |
24 | 21 | import com.android.ddmlib.ClientData; |
25 | 22 | import com.android.ddmlib.Device; |
@@ -27,6 +24,9 @@ import com.android.ddmlib.IDevice; | ||
27 | 24 | import com.android.ddmlib.Log; |
28 | 25 | import com.android.ddmlib.MultiLineReceiver; |
29 | 26 | import com.android.ddmlib.SyncService; |
27 | +import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener; | |
28 | +import com.android.ddmlib.AndroidDebugBridge.IDebugBridgeChangeListener; | |
29 | +import com.android.ddmlib.AndroidDebugBridge.IDeviceChangeListener; | |
30 | 30 | import com.android.ddmlib.SyncService.SyncResult; |
31 | 31 | import com.android.ide.eclipse.adt.AdtPlugin; |
32 | 32 | import com.android.ide.eclipse.adt.launch.AndroidLaunchConfiguration.TargetMode; |
@@ -34,10 +34,9 @@ import com.android.ide.eclipse.adt.launch.DelayedLaunchInfo.InstallRetryMode; | ||
34 | 34 | import com.android.ide.eclipse.adt.launch.DeviceChooserDialog.DeviceChooserResponse; |
35 | 35 | import com.android.ide.eclipse.adt.project.ProjectHelper; |
36 | 36 | import com.android.ide.eclipse.adt.sdk.Sdk; |
37 | -import com.android.ide.eclipse.common.AndroidConstants; | |
38 | 37 | import com.android.ide.eclipse.common.project.AndroidManifestParser; |
39 | -import com.android.prefs.AndroidLocation.AndroidLocationException; | |
40 | 38 | import com.android.ide.eclipse.common.project.BaseProjectHelper; |
39 | +import com.android.prefs.AndroidLocation.AndroidLocationException; | |
41 | 40 | import com.android.sdklib.IAndroidTarget; |
42 | 41 | import com.android.sdklib.SdkManager; |
43 | 42 | import com.android.sdklib.avd.AvdManager; |
@@ -56,7 +55,6 @@ import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy; | ||
56 | 55 | import org.eclipse.debug.core.ILaunchManager; |
57 | 56 | import org.eclipse.debug.core.model.IDebugTarget; |
58 | 57 | import org.eclipse.debug.ui.DebugUITools; |
59 | -import org.eclipse.jdt.core.IJavaModel; | |
60 | 58 | import org.eclipse.jdt.core.IJavaProject; |
61 | 59 | import org.eclipse.jdt.core.JavaModelException; |
62 | 60 | import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants; |
@@ -102,8 +100,9 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener | ||
102 | 100 | |
103 | 101 | /** |
104 | 102 | * List of {@link DelayedLaunchInfo} waiting for an emulator to connect. |
105 | - * <p>Once an emulator has connected, {@link DelayedLaunchInfo#mDevice} is set and the | |
106 | - * DelayedLaunchInfo object is moved to {@link AndroidLaunchController#mWaitingForReadyEmulatorList}. | |
103 | + * <p>Once an emulator has connected, {@link DelayedLaunchInfo#getDevice()} is set and the | |
104 | + * DelayedLaunchInfo object is moved to | |
105 | + * {@link AndroidLaunchController#mWaitingForReadyEmulatorList}. | |
107 | 106 | * <b>ALL ACCESS MUST BE INSIDE A <code>synchronized (sListLock)</code> block!</b> |
108 | 107 | */ |
109 | 108 | private final ArrayList<DelayedLaunchInfo> mWaitingForEmulatorLaunches = |
@@ -487,7 +486,7 @@ public final class AndroidLaunchController implements IDebugBridgeChangeListener | ||
487 | 486 | // FIXME: ask the user if he wants to create a AVD. |
488 | 487 | // we found no compatible AVD. |
489 | 488 | AdtPlugin.printErrorToConsole(project, String.format( |
490 | - "Failed to find a AVD compatible with target '%1$s'. Launch aborted.", | |
489 | + "Failed to find an AVD compatible with target '%1$s'. Launch aborted.", | |
491 | 490 | projectTarget.getName())); |
492 | 491 | stopLaunch(launchInfo); |
493 | 492 | return; |
@@ -57,7 +57,7 @@ class AndroidJUnitLaunchAction implements IAndroidLaunchAction { | ||
57 | 57 | * Launch a instrumentation test run on given Android device. |
58 | 58 | * Reuses JDT JUnit launch delegate so results can be communicated back to JDT JUnit UI. |
59 | 59 | * |
60 | - * @see com.android.ide.eclipse.adt.launch.IAndroidLaunchAction#doLaunchAction(com.android.ide.eclipse.adt.launch.AndroidLaunchController.DelayedLaunchInfo, com.android.ddmlib.Device) | |
60 | + * @see IAndroidLaunchAction#doLaunchAction(DelayedLaunchInfo, IDevice) | |
61 | 61 | */ |
62 | 62 | public boolean doLaunchAction(DelayedLaunchInfo info, IDevice device) { |
63 | 63 | String msg = String.format("Launching instrumentation %s on device %s", mRunner, |
@@ -108,7 +108,9 @@ class AndroidJUnitLaunchAction implements IAndroidLaunchAction { | ||
108 | 108 | super.launch(configuration, mode, launch, monitor); |
109 | 109 | } |
110 | 110 | |
111 | - /* (non-Javadoc) | |
111 | + /** | |
112 | + * {@inheritDoc} | |
113 | + * @throws CoreException | |
112 | 114 | * @see org.eclipse.jdt.junit.launcher.JUnitLaunchConfigurationDelegate#verifyMainTypeName(org.eclipse.debug.core.ILaunchConfiguration) |
113 | 115 | */ |
114 | 116 | @Override |
@@ -119,6 +121,7 @@ class AndroidJUnitLaunchAction implements IAndroidLaunchAction { | ||
119 | 121 | /** |
120 | 122 | * Overrides parent to return a VM Runner implementation which launches a thread, rather |
121 | 123 | * than a separate VM process |
124 | + * @throws CoreException | |
122 | 125 | */ |
123 | 126 | @Override |
124 | 127 | public IVMRunner getVMRunner(ILaunchConfiguration configuration, String mode) |
@@ -127,7 +130,9 @@ class AndroidJUnitLaunchAction implements IAndroidLaunchAction { | ||
127 | 130 | mTestPackage, mRunner, mLaunchInfo.isDebugMode(), mDevice)); |
128 | 131 | } |
129 | 132 | |
130 | - /* (non-Javadoc) | |
133 | + /** | |
134 | + * {@inheritDoc} | |
135 | + * @throws CoreException | |
131 | 136 | * @see org.eclipse.debug.core.model.LaunchConfigurationDelegate#getLaunch(org.eclipse.debug.core.ILaunchConfiguration, java.lang.String) |
132 | 137 | */ |
133 | 138 | @Override |
@@ -148,6 +153,10 @@ class AndroidJUnitLaunchAction implements IAndroidLaunchAction { | ||
148 | 153 | mJUnitInfo = info; |
149 | 154 | } |
150 | 155 | |
156 | + /** | |
157 | + * {@inheritDoc} | |
158 | + * @throws CoreException | |
159 | + */ | |
151 | 160 | public void run(final VMRunnerConfiguration config, ILaunch launch, |
152 | 161 | IProgressMonitor monitor) throws CoreException { |
153 | 162 |
@@ -183,7 +192,9 @@ class AndroidJUnitLaunchAction implements IAndroidLaunchAction { | ||
183 | 192 | return null; |
184 | 193 | } |
185 | 194 | |
186 | - /* (non-Javadoc) | |
195 | + /** | |
196 | + * {@inheritDoc} | |
197 | + * @throws DebugException | |
187 | 198 | * @see org.eclipse.debug.core.model.IProcess#getExitValue() |
188 | 199 | */ |
189 | 200 | public int getExitValue() throws DebugException { |
@@ -241,7 +252,9 @@ class AndroidJUnitLaunchAction implements IAndroidLaunchAction { | ||
241 | 252 | return mIsTerminated; |
242 | 253 | } |
243 | 254 | |
244 | - /* (non-Javadoc) | |
255 | + /** | |
256 | + * {@inheritDoc} | |
257 | + * @throws DebugException | |
245 | 258 | * @see org.eclipse.debug.core.model.ITerminate#terminate() |
246 | 259 | */ |
247 | 260 | public void terminate() throws DebugException { |