StubDevice

public class StubDevice
extends Object implements IDevice

java.lang.object
com.android.tradefed.device.StubDevice


اجرای مکان‌دار خرد یک IDevice .

خلاصه

سازندگان عمومی

StubDevice (String serial)
StubDevice (String serial, boolean isEmulator)

روش های عمومی

boolean arePropertiesSet ()

void createForward (int localPort, String remoteSocketName, IDevice.DeviceUnixSocketNamespace namespace)

void createForward (int localPort, int remotePort)

void createReverse (int remotePort, int localPort)

void executeShellCommand (String command, IShellOutputReceiver receiver, long maxTimeToOutputResponse, TimeUnit maxTimeUnits)

void executeShellCommand (String command, IShellOutputReceiver receiver)

void executeShellCommand (String command, IShellOutputReceiver receiver, int maxTimeToOutputResponse)

این روش منسوخ شده است. از executeShellCommand(String, com.android.ddmlib.IShellOutputReceiver, long, TimeUnit) استفاده کنید.

void executeShellCommand (String command, IShellOutputReceiver receiver, long maxTimeout, long maxTimeToOutputResponse, TimeUnit maxTimeUnits)

getAbis ()

String getAvdName ()

String getAvdPath ()

getBattery (long freshnessTime, TimeUnit timeUnit)

getBattery ()

Integer getBatteryLevel (long freshnessMs)

این روش منسوخ شده است. به جای آن از getBattery(long, TimeUnit) استفاده کنید.

Integer getBatteryLevel ()

این روش منسوخ شده است. به جای آن از getBattery() استفاده کنید.

Client getClient (String applicationName)

String getClientName (int pid)

Client[] getClients ()

int getDensity ()

FileListingService getFileListingService ()

String getLanguage ()

String getMountPoint (String name)

String getName ()

getProperties ()

این روش منسوخ شده است. به جای آن از getSystemProperty(String) استفاده کنید.

String getProperty (String name)

String getPropertyCacheOrSync (String name)

این روش منسوخ شده است. به جای آن از getProperty(String) استفاده کنید.

int getPropertyCount ()

این روش منسوخ شده است. در ddmlib با "جزئیات پیاده سازی" به عنوان دلیل منسوخ شده است.

String getPropertySync (String name)

این روش منسوخ شده است. به جای آن از getProperty(String) استفاده کنید.

String getRegion ()

RawImage getScreenshot ()

RawImage getScreenshot (long timeout, TimeUnit unit)
String getSerialNumber ()

IDevice.DeviceState getState ()

SyncService getSyncService ()

ListenableFuture<String> getSystemProperty (String name)

AndroidVersion getVersion ()

boolean hasClients ()

void installPackage (String packageFilePath, boolean reinstall, InstallReceiver receiver, long maxTimeout, long maxTimeToOutputResponse, TimeUnit maxTimeUnits, String... extraArgs)

void installPackage (String packageFilePath, boolean reinstall, InstallReceiver receiver, String... extraArgs)

void installPackage (String packageFilePath, boolean reinstall, String... extraArgs)

void installPackages ( apkFilePaths, boolean reinstall, extraArgs, long timeOutInMs, TimeUnit timeunit) installPackages ( apkFilePaths, boolean reinstall, extraArgs, long timeOutInMs, TimeUnit timeunit) installPackages ( apkFilePaths, boolean reinstall, extraArgs, long timeOutInMs, TimeUnit timeunit)

void installRemotePackage (String remoteFilePath, boolean reinstall, InstallReceiver receiver, String... extraArgs)

void installRemotePackage (String remoteFilePath, boolean reinstall, String... extraArgs)

void installRemotePackage (String remoteFilePath, boolean reinstall, InstallReceiver receiver, long maxTimeout, long maxTimeToOutputResponse, TimeUnit maxTimeUnits, String... extraArgs)

boolean isBootLoader ()

boolean isEmulator ()

boolean isOffline ()

boolean isOnline ()

boolean isRoot ()

void pullFile (String remote, String local)

void pushFile (String local, String remote)

void reboot (String into)

void removeForward (int localPort)

void removeForward (int localPort, int remotePort)

void removeForward (int localPort, String remoteSocketName, IDevice.DeviceUnixSocketNamespace namespace)

void removeRemotePackage (String remoteFilePath)

void removeReverse (int remotePort)

boolean root ()

void runEventLogService (LogReceiver receiver)

void runLogService (String logname, LogReceiver receiver)

void setSerial (String serial)
void startScreenRecorder (String remoteFilePath, ScreenRecorderOptions options, IShellOutputReceiver receiver)

boolean supportsFeature (IDevice.HardwareFeature arg0)
boolean supportsFeature (IDevice.Feature feature)

String syncPackageToDevice (String localFilePath)

String uninstallApp (String applicationID, String... extraArgs)

String uninstallPackage (String packageName)

سازندگان عمومی

StubDevice

public StubDevice (String serial)

مولفه های
serial String

StubDevice

public StubDevice (String serial, 
                boolean isEmulator)

مولفه های
serial String

isEmulator boolean

روش های عمومی

arePropertiesSet

public boolean arePropertiesSet ()

برمی گرداند
boolean

ایجاد به جلو

public void createForward (int localPort, 
                String remoteSocketName, 
                IDevice.DeviceUnixSocketNamespace namespace)

مولفه های
localPort int

remoteSocketName String

namespace IDevice.DeviceUnixSocketNamespace

پرتاب می کند
AdbCommandRejectedException
TimeoutException

ایجاد به جلو

public void createForward (int localPort, 
                int remotePort)

مولفه های
localPort int

remotePort int

پرتاب می کند
AdbCommandRejectedException
TimeoutException

ایجاد معکوس

public void createReverse (int remotePort, 
                int localPort)

مولفه های
remotePort int

localPort int

پرتاب می کند
AdbCommandRejectedException
TimeoutException

ShellCommand را اجرا کنید

public void executeShellCommand (String command, 
                IShellOutputReceiver receiver, 
                long maxTimeToOutputResponse, 
                TimeUnit maxTimeUnits)

مولفه های
command String

receiver IShellOutputReceiver

maxTimeToOutputResponse long

maxTimeUnits TimeUnit

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

ShellCommand را اجرا کنید

public void executeShellCommand (String command, 
                IShellOutputReceiver receiver)

مولفه های
command String

receiver IShellOutputReceiver

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

ShellCommand را اجرا کنید

public void executeShellCommand (String command, 
                IShellOutputReceiver receiver, 
                int maxTimeToOutputResponse)

این روش منسوخ شده است.
از executeShellCommand(String, com.android.ddmlib.IShellOutputReceiver, long, TimeUnit) استفاده کنید.

مولفه های
command String

receiver IShellOutputReceiver

maxTimeToOutputResponse int

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

ShellCommand را اجرا کنید

public void executeShellCommand (String command, 
                IShellOutputReceiver receiver, 
                long maxTimeout, 
                long maxTimeToOutputResponse, 
                TimeUnit maxTimeUnits)

مولفه های
command String

receiver IShellOutputReceiver

maxTimeout long

maxTimeToOutputResponse long

maxTimeUnits TimeUnit

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

getAbis

public  getAbis ()

برمی گرداند

getAvdName

public String getAvdName ()

برمی گرداند
String

getAvdPath

public String getAvdPath ()

برمی گرداند
String

دریافت باتری

public  getBattery (long freshnessTime, 
                TimeUnit timeUnit)

مولفه های
freshnessTime long

timeUnit TimeUnit

برمی گرداند

دریافت باتری

public  getBattery ()

برمی گرداند

getBatteryLevel

public Integer getBatteryLevel (long freshnessMs)

این روش منسوخ شده است.
به جای آن از getBattery(long, TimeUnit) استفاده کنید.

مولفه های
freshnessMs long

برمی گرداند
Integer

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

getBatteryLevel

public Integer getBatteryLevel ()

این روش منسوخ شده است.
به جای آن از getBattery() استفاده کنید.

برمی گرداند
Integer

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

getClient

public Client getClient (String applicationName)

مولفه های
applicationName String

برمی گرداند
Client

getClientName

public String getClientName (int pid)

مولفه های
pid int

برمی گرداند
String

getClients

public Client[] getClients ()

برمی گرداند
Client[]

دریافت تراکم

public int getDensity ()

برمی گرداند
int

getFileListingService

public FileListingService getFileListingService ()

برمی گرداند
FileListingService

getLanguage

public String getLanguage ()

برمی گرداند
String

getMountPoint

public String getMountPoint (String name)

مولفه های
name String

برمی گرداند
String

getName

public String getName ()

برمی گرداند
String

getProperties

public  getProperties ()

این روش منسوخ شده است.
به جای آن از getSystemProperty(String) استفاده کنید.

برمی گرداند

getProperty

public String getProperty (String name)

مولفه های
name String

برمی گرداند
String

getPropertyCacheOrSync

public String getPropertyCacheOrSync (String name)

این روش منسوخ شده است.
به جای آن از getProperty(String) استفاده کنید.

مولفه های
name String

برمی گرداند
String

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

getPropertyCount

public int getPropertyCount ()

این روش منسوخ شده است.
در ddmlib با "جزئیات پیاده سازی" به عنوان دلیل منسوخ شده است.

برمی گرداند
int

getPropertySync

public String getPropertySync (String name)

این روش منسوخ شده است.
به جای آن از getProperty(String) استفاده کنید.

مولفه های
name String

برمی گرداند
String

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

getRegion

public String getRegion ()

برمی گرداند
String

دریافت اسکرین شات

public RawImage getScreenshot ()

برمی گرداند
RawImage

پرتاب می کند
AdbCommandRejectedException
TimeoutException

دریافت اسکرین شات

public RawImage getScreenshot (long timeout, 
                TimeUnit unit)

مولفه های
timeout long

unit TimeUnit

برمی گرداند
RawImage

پرتاب می کند
AdbCommandRejectedException
TimeoutException

دریافت شماره سریال

public String getSerialNumber ()

برمی گرداند
String

getState

public IDevice.DeviceState getState ()

برمی گرداند
IDevice.DeviceState

getSyncService

public SyncService getSyncService ()

برمی گرداند
SyncService

پرتاب می کند
AdbCommandRejectedException
TimeoutException

getSystemProperty

public ListenableFuture<String> getSystemProperty (String name)

مولفه های
name String

برمی گرداند
ListenableFuture<String>

getVersion

public AndroidVersion getVersion ()

برمی گرداند
AndroidVersion

دارای مشتریان است

public boolean hasClients ()

برمی گرداند
boolean

installPackage

public void installPackage (String packageFilePath, 
                boolean reinstall, 
                InstallReceiver receiver, 
                long maxTimeout, 
                long maxTimeToOutputResponse, 
                TimeUnit maxTimeUnits, 
                String... extraArgs)

مولفه های
packageFilePath String

reinstall boolean

receiver InstallReceiver

maxTimeout long

maxTimeToOutputResponse long

maxTimeUnits TimeUnit

extraArgs String

پرتاب می کند
InstallException

installPackage

public void installPackage (String packageFilePath, 
                boolean reinstall, 
                InstallReceiver receiver, 
                String... extraArgs)

مولفه های
packageFilePath String

reinstall boolean

receiver InstallReceiver

extraArgs String

پرتاب می کند
InstallException

installPackage

public void installPackage (String packageFilePath, 
                boolean reinstall, 
                String... extraArgs)

مولفه های
packageFilePath String

reinstall boolean

extraArgs String

پرتاب می کند
InstallException

installPackages

public void installPackages ( apkFilePaths, 
                boolean reinstall, 
                 extraArgs, 
                long timeOutInMs, 
                TimeUnit timeunit)

مولفه های
apkFilePaths

reinstall boolean

extraArgs

timeOutInMs long

timeunit TimeUnit

پرتاب می کند
InstallException

RemotePackage را نصب کنید

public void installRemotePackage (String remoteFilePath, 
                boolean reinstall, 
                InstallReceiver receiver, 
                String... extraArgs)

مولفه های
remoteFilePath String

reinstall boolean

receiver InstallReceiver

extraArgs String

پرتاب می کند
InstallException

RemotePackage را نصب کنید

public void installRemotePackage (String remoteFilePath, 
                boolean reinstall, 
                String... extraArgs)

مولفه های
remoteFilePath String

reinstall boolean

extraArgs String

پرتاب می کند
InstallException

RemotePackage را نصب کنید

public void installRemotePackage (String remoteFilePath, 
                boolean reinstall, 
                InstallReceiver receiver, 
                long maxTimeout, 
                long maxTimeToOutputResponse, 
                TimeUnit maxTimeUnits, 
                String... extraArgs)

مولفه های
remoteFilePath String

reinstall boolean

receiver InstallReceiver

maxTimeout long

maxTimeToOutputResponse long

maxTimeUnits TimeUnit

extraArgs String

پرتاب می کند
InstallException

isBootLoader است

public boolean isBootLoader ()

برمی گرداند
boolean

isEmulator

public boolean isEmulator ()

برمی گرداند
boolean

آفلاین است

public boolean isOffline ()

برمی گرداند
boolean

برخط است

public boolean isOnline ()

برمی گرداند
boolean

isRoot

public boolean isRoot ()

برمی گرداند
boolean

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

pullFile

public void pullFile (String remote, 
                String local)

مولفه های
remote String

local String

پرتاب می کند
AdbCommandRejectedException
SyncException
TimeoutException

pushFile

public void pushFile (String local, 
                String remote)

مولفه های
local String

remote String

پرتاب می کند
AdbCommandRejectedException
SyncException
TimeoutException

راه اندازی مجدد

public void reboot (String into)

مولفه های
into String

پرتاب می کند
AdbCommandRejectedException
TimeoutException

removeForward

public void removeForward (int localPort)

مولفه های
localPort int

پرتاب می کند
AdbCommandRejectedException
TimeoutException

removeForward

public void removeForward (int localPort, 
                int remotePort)

مولفه های
localPort int

remotePort int

پرتاب می کند
AdbCommandRejectedException
TimeoutException

removeForward

public void removeForward (int localPort, 
                String remoteSocketName, 
                IDevice.DeviceUnixSocketNamespace namespace)

مولفه های
localPort int

remoteSocketName String

namespace IDevice.DeviceUnixSocketNamespace

پرتاب می کند
AdbCommandRejectedException
TimeoutException

حذف RemotePackage

public void removeRemotePackage (String remoteFilePath)

مولفه های
remoteFilePath String

پرتاب می کند
InstallException

removeReverse

public void removeReverse (int remotePort)

مولفه های
remotePort int

پرتاب می کند
AdbCommandRejectedException
TimeoutException

ریشه

public boolean root ()

برمی گرداند
boolean

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

runEventLogService

public void runEventLogService (LogReceiver receiver)

مولفه های
receiver LogReceiver

پرتاب می کند
AdbCommandRejectedException
TimeoutException

runLogService

public void runLogService (String logname, 
                LogReceiver receiver)

مولفه های
logname String

receiver LogReceiver

پرتاب می کند
AdbCommandRejectedException
TimeoutException

مجموعه سریال

public void setSerial (String serial)

مولفه های
serial String

startScreenRecorder

public void startScreenRecorder (String remoteFilePath, 
                ScreenRecorderOptions options, 
                IShellOutputReceiver receiver)

مولفه های
remoteFilePath String

options ScreenRecorderOptions

receiver IShellOutputReceiver

پرتاب می کند
AdbCommandRejectedException
ShellCommandUnresponsiveException
TimeoutException

پشتیبانی از ویژگی

public boolean supportsFeature (IDevice.HardwareFeature arg0)

مولفه های
arg0 IDevice.HardwareFeature

برمی گرداند
boolean

پشتیبانی از ویژگی

public boolean supportsFeature (IDevice.Feature feature)

مولفه های
feature IDevice.Feature

برمی گرداند
boolean

syncPackageToDevice

public String syncPackageToDevice (String localFilePath)

مولفه های
localFilePath String

برمی گرداند
String

پرتاب می کند
AdbCommandRejectedException
SyncException
TimeoutException

حذف برنامه

public String uninstallApp (String applicationID, 
                String... extraArgs)

مولفه های
applicationID String

extraArgs String

برمی گرداند
String

پرتاب می کند
InstallException

UninstallPackage

public String uninstallPackage (String packageName)

مولفه های
packageName String

برمی گرداند
String

پرتاب می کند
InstallException