?? emulator.java
字號:
package org.momeunit.ant.emulator;import java.io.File;import org.momeunit.ant.core.WtkTool;/** * Abstract base class of all emulators. Extends {@link WtkTool}. Contains * {@link #execute(String, File, File)} abstract method that every emulator must * implement. Contains <code>device</code> property accessible via * {@link #setDevice(String)} and {@link #getDevice()} methods. * * @author Sergio Morozov * @version 1.1.2 */public abstract class Emulator extends WtkTool{ /** * Name of device property. * * @since 1.1 */ public static final String DEVICE_PROPERTY = "device"; /** * Instantiates emulator with given WTK home directory. * * @param wtkHome * WTK home directory. * @since 1.1 */ public Emulator(File wtkHome) { super(wtkHome); } /** * Instantiates emulator. * * @since 1.1 */ public Emulator() { this(null); } /** * Returns the device used when running emulator. * * @return used device. * @since 1.1 */ public String getDevice() { return getProperty(DEVICE_PROPERTY); } /** * Sets the device used when running emulator. * * @param device * device to use. * @since 1.1 */ public void setDevice(String device) { setProperty(DEVICE_PROPERTY, device); } /** * Abstract method intended to start emulator that every emulator must * implement. * * @param midletClass * classname of midlet to start. Can be <code>null</code>. * @param jad * JAD descriptor of application to run. Can be <code>null</code>. * @param jar * Jar archive of application to run. Can be <code>null</code>. * @return {@link Process} associated with running emulator. * @since 1.1 */ public abstract Process execute(String midletClass, File jad, File jar);}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -