Google은 흑인 공동체를 위한 인종 간 평등을 진전시키기 위해 노력하고 있습니다. Google에서 어떤 노력을 하고 있는지 확인하세요.

NativeDevice

public class NativeDevice
extends Object implements IManagedTestDevice

java.lang.Object
com.android.tradefed.device.NativeDevice


ITestDevice Non-full stack android 장치의 기본 구현입니다.

요약

중첩 된 클래스

class NativeDevice.AdbAction

OS 'adb ....'명령을 실행하기위한 DeviceAction .

class NativeDevice.AdbShellAction

class NativeDevice.RebootDeviceAction

장치 재부팅을위한 DeviceAction .

enum NativeDevice.RebootMode

재부팅 모드.

상수

int INVALID_USER_ID

유효하지 않거나 찾을 수없는 사용자 ID에 대해 반환 된 값 : UserHandle이 -10000 값을 정의했습니다.

long MAX_HOST_DEVICE_TIME_OFFSET

int MAX_RETRY_ATTEMPTS

수행하려는 기본 명령 재시도 횟수

필드

protected static final String SD_CARD

protected TestDeviceOptions mOptions

protected final IDeviceStateMonitor mStateMonitor

공용 생성자

NativeDevice (IDevice device, IDeviceStateMonitor stateMonitor, IDeviceMonitor allocationMonitor)

TestDevice 만듭니다.

공개 방법

boolean checkApiLevelAgainstNextRelease (int strictMinLevel)

boolean checkConnectivity ()

boolean clearErrorDialogs ()

void clearLastConnectedWifiNetwork ()

void clearLogcat ()

boolean connectToWifiNetwork (String wifiSsid, String wifiPsk)

boolean connectToWifiNetwork (String wifiSsid, String wifiPsk, boolean scanSsid)

boolean connectToWifiNetworkIfNeeded (String wifiSsid, String wifiPsk, boolean scanSsid)

boolean connectToWifiNetworkIfNeeded (String wifiSsid, String wifiPsk)

int createUser (String name, boolean guest, boolean ephemeral)

int createUser (String name)

int createUserNoThrow (String name)

void deleteFile (String deviceFilePath)

boolean deviceSoftRestarted (ProcessInfo prevSystemServerProcess)

boolean deviceSoftRestartedSince (long utcEpochTime, TimeUnit timeUnit)

boolean disableAdbRoot ()

void disableKeyguard ()

boolean disableNetworkMonitor ()

boolean disconnectFromWifi ()

boolean doesFileExist (String deviceFilePath)

File dumpHeap (String process, String devicePath)

boolean enableAdbRoot ()

boolean enableNetworkMonitor ()

boolean encryptDevice (boolean inplace)

String executeAdbCommand (long timeout, String... cmdArgs)

String executeAdbCommand (String... cmdArgs)

CommandResult executeFastbootCommand (String... cmdArgs)

CommandResult executeFastbootCommand (long timeout, String... cmdArgs)

CommandResult executeLongFastbootCommand (String... cmdArgs)

String executeShellCommand (String command)

void executeShellCommand (String command, IShellOutputReceiver receiver, long maxTimeToOutputShellResponse, TimeUnit timeUnit, int retryAttempts)

void executeShellCommand (String command, IShellOutputReceiver receiver, long maxTimeoutForCommand, long maxTimeToOutputShellResponse, TimeUnit timeUnit, int retryAttempts)

void executeShellCommand (String command, IShellOutputReceiver receiver)

CommandResult executeShellV2Command (String cmd)

CommandResult executeShellV2Command (String cmd, OutputStream pipeToOutput)

CommandResult executeShellV2Command (String cmd, File pipeAsInput)

CommandResult executeShellV2Command (String cmd, long maxTimeoutForCommand, TimeUnit timeUnit, int retryAttempts)

CommandResult executeShellV2Command (String cmd, long maxTimeoutForCommand, TimeUnit timeUnit)

CommandResult executeShellV2Command (String cmd, File pipeAsInput, OutputStream pipeToOutput, long maxTimeoutForCommand, TimeUnit timeUnit, int retryAttempts)

CommandResult fastbootWipePartition (String partition)

getActiveApexes ()

getAllSettings (String namespace)

DeviceAllocationState getAllocationState ()
String getAndroidId (int userId)

getAndroidIds ()

int getApiLevel ()

PackageInfo getAppPackageInfo (String packageName)

getAppPackageInfos ()

String getBasebandVersion ()
Integer getBattery ()

boolean getBooleanProperty (String name, boolean defaultValue)

getBootHistory ()

getBootHistorySince (long utcEpochTime, TimeUnit timeUnit)

String getBootloaderVersion ()

InputStreamSource getBugreport ()

InputStreamSource getBugreportz ()

String getBuildAlias ()

String getBuildFlavor ()

String getBuildId ()

String getBuildSigningKeys ()

DeviceDescriptor getCachedDeviceDescriptor ()

String[] getChildren (String path)

int getCurrentUser ()

String getDeviceClass ()

long getDeviceDate ()

DeviceDescriptor getDeviceDescriptor ()

TestDeviceState getDeviceState ()

long getDeviceTimeOffset (Date date)

InputStreamSource getEmulatorOutput ()

Process getEmulatorProcess ()

final File getExecuteShellCommandLog ()

모든 executeShellCommand(String) 로그를 포함하는 로그입니다.

long getExternalStoreFreeSpace ()

String getFastbootPath ()

String getFastbootProductType ()

String getFastbootProductVariant ()

String getFastbootVariable (String variableName)

String getFastbootVersion ()

IFileEntry getFileEntry (String path)

IFileEntry getFileEntry (FileListingService.FileEntry entry)

루트가 아닌 경로에서 FileEntry 를 가져 오는 비공식 도우미입니다.

IDevice getIDevice ()

getInstalledPackageNames ()

long getIntProperty (String name, long defaultValue)

String getIpAddress ()

KeyguardControllerState getKeyguardState ()

long getLastExpectedRebootTimeMillis ()

int getLaunchApiLevel ()

InputStreamSource getLogcat ()

InputStreamSource getLogcat (int maxBytes)

InputStreamSource getLogcatDump ()

InputStreamSource getLogcatSince (long date)

String getMacAddress ()

int getMaxNumberOfRunningUsersSupported ()
int getMaxNumberOfUsersSupported ()

IDeviceStateMonitor getMonitor ()
String getMountPoint (String mountName)

ITestDevice.MountPointInfo getMountPointInfo (String mountpoint)

getMountPointInfo ()

TestDeviceOptions getOptions ()

long getPartitionFreeSpace (String partition)

Integer getPrimaryUserId ()

ProcessInfo getProcessByName (String processName)

String getProcessPid (String process)

String getProductType ()

String getProductVariant ()

String getProperty (String name)

ITestDevice.RecoveryMode getRecoveryMode ()

InputStreamSource getScreenshot (String format)

InputStreamSource getScreenshot (long displayId)

InputStreamSource getScreenshot (String format, boolean rescale)

InputStreamSource getScreenshot ()

String getSerialNumber ()

String getSetting (int userId, String namespace, String key)

String getSetting (String namespace, String key)

String getSimOperator ()

String getSimState ()

getTombstones ()

long getTotalMemory ()

getUninstallablePackageNames ()

boolean getUseFastbootErase ()

int getUserFlags (int userId)

getUserInfos ()

int getUserSerialNumber (int userId)

IManagedTestDevice.DeviceEventResponse handleAllocationEvent (DeviceEvent event)

이 장치를 새 할당 상태로 전환하거나 전환하지 않을 수있는 DeviceEvent를 처리합니다.

boolean hasFeature (String feature)

String installPackage (File packageFile, boolean reinstall, String... extraArgs)

String installPackage (File packageFile, boolean reinstall, boolean grantPermissions, String... extraArgs)

String installPackageForUser (File packageFile, boolean reinstall, int userId, String... extraArgs)

String installPackageForUser (File packageFile, boolean reinstall, boolean grantPermissions, int userId, String... extraArgs)

boolean isAdbRoot ()

boolean isAdbTcp ()
boolean isAppEnumerationSupported ()

boolean isDeviceEncrypted ()

boolean isDirectory (String path)

boolean isEnableAdbRoot ()
boolean isEncryptionSupported ()

boolean isExecutable (String fullPath)

boolean isFastbootEnabled ()

boolean isHeadless ()

boolean isMultiUserSupported ()

boolean isPackageInstalled (String packageName, String userId)

boolean isPackageInstalled (String packageName)

boolean isRuntimePermissionSupported ()

boolean isStateBootloaderOrFastbootd ()

boolean isUserRunning (int userId)

boolean isUserSecondary (int userId)

boolean isWifiEnabled ()

listDisplayIds ()

listUsers ()

boolean logBugreport (String dataName, ITestLogger listener)

void logOnDevice (String tag, Log.LogLevel level, String format, Object... args)

void nonBlockingReboot ()

void postAdbRootAction ()

adb root 후 기기가 다시 온라인 상태가되기 전에 기기에 특정 작업을 수행해야하는 경우 재정의합니다.

void postAdbUnrootAction ()

adb unroot 후 기기가 다시 온라인 상태가되기 전에 기기에 특정 작업을 수행해야하는 경우 재정의합니다.

void postBootSetup ()

void postInvocationTearDown (Throwable exception)

void preInvocationSetup (IBuildInfo info)

boolean pullDir (String deviceFilePath, File localDir)

boolean pullFile (String remoteFilePath, File localFile)

File pullFile (String remoteFilePath)

String pullFileContents (String remoteFilePath)

File pullFileFromExternal (String remoteFilePath)

boolean pushDir (File localFileDir, String deviceFilePath, excludedDirectories) pushDir (File localFileDir, String deviceFilePath, excludedDirectories)

boolean pushDir (File localFileDir, String deviceFilePath)

boolean pushFile (File localFile, String remoteFilePath)

boolean pushString (String contents, String remoteFilePath)

void reboot (String reason)

void reboot ()

void rebootIntoBootloader ()

void rebootIntoFastbootd ()

void rebootIntoRecovery ()

void rebootIntoSideload ()

void rebootIntoSideload (boolean autoReboot)

void rebootUntilOnline ()
void rebootUntilOnline (String reason)

void rebootUserspace ()
void rebootUserspaceUntilOnline ()
void recoverDevice ()

장치 통신 복구를 시도합니다.

void remountSystemWritable ()

void remountVendorWritable ()

boolean removeAdmin (String componentName, int userId)

void removeOwners ()

boolean removeUser (int userId)

boolean runInstrumentationTests (IRemoteAndroidTestRunner runner, ITestLifeCycleReceiver... listeners)

boolean runInstrumentationTests (IRemoteAndroidTestRunner runner, listeners) runInstrumentationTests (IRemoteAndroidTestRunner runner, listeners)

boolean runInstrumentationTestsAsUser (IRemoteAndroidTestRunner runner, int userId, ITestLifeCycleReceiver... listeners)

boolean runInstrumentationTestsAsUser (IRemoteAndroidTestRunner runner, int userId, listeners) runInstrumentationTestsAsUser (IRemoteAndroidTestRunner runner, int userId, listeners)

void setDate (Date date)

boolean setDeviceOwner (String componentName, int userId)

void setDeviceState (TestDeviceState deviceState)

void setEmulatorOutputStream ( SizeLimitedOutputStream output)

에뮬레이터의 경우 SizeLimitedOutputStream 을 로그 출력으로 설정합니다.

void setEmulatorProcess (Process p)

void setFastbootEnabled (boolean fastbootEnabled)

void setFastbootPath (String fastbootPath)

void setIDevice (IDevice newDevice)

void setOptions (TestDeviceOptions options)

boolean setProperty (String propKey, String propValue)

void setRecovery (IDeviceRecovery recovery)

void setRecoveryMode (ITestDevice.RecoveryMode mode)

void setSetting (String namespace, String key, String value)

void setSetting (int userId, String namespace, String key, String value)

void setUseFastbootErase (boolean useFastbootErase)

void startLogcat ()

boolean startUser (int userId)

boolean startUser (int userId, boolean waitFlag)

void stopEmulatorOutput ()

void stopLogcat ()

boolean stopUser (int userId)

boolean stopUser (int userId, boolean waitFlag, boolean forceFlag)

String switchToAdbTcp ()

boolean switchToAdbUsb ()

boolean switchUser (int userId)

boolean switchUser (int userId, long timeout)

boolean syncFiles (File localFileDir, String deviceFilePath)

Bugreport takeBugreport ()

boolean unencryptDevice ()

String uninstallPackage (String packageName)

boolean unlockDevice ()

boolean waitForBootComplete (long timeOut)

void waitForDeviceAvailable ()

void waitForDeviceAvailable (long waitTime)

boolean waitForDeviceInRecovery (long waitTime)

boolean waitForDeviceInSideload (long waitTime)

boolean waitForDeviceNotAvailable (long waitTime)

void waitForDeviceOnline ()

void waitForDeviceOnline (long waitTime)

boolean waitForDeviceShell (long waitTime)

보호 된 방법

void checkApiLevelAgainst (String feature, int strictMinLevel)
NativeDevice.RebootDeviceAction createRebootDeviceAction ( NativeDevice.RebootMode rebootMode, String reason)

재부팅 작업을 수행 할 때 사용할 RebootDeviceAction 을 만듭니다.

void doAdbReboot ( NativeDevice.RebootMode rebootMode, String reason)

adb 재부팅을 수행합니다.

void ensureRuntimePermissionSupported ()

런타임 권한이 지원되지 않는 경우 예외를 throw하는 도우미 메서드

InputStreamSource getBugreportInternal ()
File getBugreportzInternal ()

bugreportz zip 파일을 ERROR(/File) 로 가져 오는 내부 도우미 메서드입니다.

IRunUtil getRunUtil ()

사용할 RunUtil 인스턴스를 RunUtil .

String internalGetProperty (String propName, String fastbootVar, String description)

기본적으로 ddmlib 캐시에서 장치 속성을 가져오고 장치가 Fastboot에 있는지 여부에 따라`adb shell getprop` 또는`fastboot getvar`로 폴백합니다.

boolean isNewer (File localFile, IFileEntry entry)

로컬 파일이 원격 파일보다 새로운 경우 true 반환 true .

boolean performDeviceAction (String actionDescription, com.android.tradefed.device.NativeDevice.DeviceAction action, int retryAttempts)

이 장치에서 작업을 수행합니다.

void postAdbReboot ()

재부팅 후 취할 수있는 가능한 추가 조치.

void prePostBootSetup ()

각 기기 유형 (AndroidNativeDevice, TestDevice)이 특정 부팅 후 설정에 대해이 메서드를 재정의하도록 허용합니다.

void setClock (Clock clock)

사용할 Clock 인스턴스를 설정합니다.

void setLogStartDelay (int delay)

온라인 장치의 logcat 캡처를 시작하기 전에 대기 할 시간 (ms)을 설정합니다.

void waitForDeviceNotAvailable (String operationDesc, long time)

상수

INVALID_USER_ID

public static final int INVALID_USER_ID

유효하지 않거나 찾을 수없는 사용자 ID에 대해 반환 된 값 : UserHandle이 -10000 값을 정의했습니다.

상수 값 : -10000 (0xffffd8f0)

MAX_HOST_DEVICE_TIME_OFFSET

protected static final long MAX_HOST_DEVICE_TIME_OFFSET

상수 값 : 5000 (0x0000000000001388)

MAX_RETRY_ATTEMPTS

protected static final int MAX_RETRY_ATTEMPTS

수행하려는 기본 명령 재시도 횟수

상수 값 : 2 (0x00000002)

필드

SD_CARD

protected static final String SD_CARD

m 옵션

protected TestDeviceOptions mOptions

mStateMonitor

protected final IDeviceStateMonitor mStateMonitor

공용 생성자

NativeDevice

public NativeDevice (IDevice device, 
                IDeviceStateMonitor stateMonitor, 
                IDeviceMonitor allocationMonitor)

TestDevice 만듭니다.

매개 변수
device IDevice : 관련 IDevice

stateMonitor IDeviceStateMonitor : 사용할 IDeviceStateMonitor 메커니즘

allocationMonitor IDeviceMonitor : 할당 상태 변경을 알리는 IDeviceMonitor . null 일 수 있음

공개 방법

checkApiLevelAgainstNextRelease

public boolean checkApiLevelAgainstNextRelease (int strictMinLevel)

매개 변수
strictMinLevel int

보고
boolean

던짐
DeviceNotAvailableException

checkConnectivity

public boolean checkConnectivity ()

보고
boolean

던짐
DeviceNotAvailableException

clearErrorDialogs

public boolean clearErrorDialogs ()

보고
boolean

던짐
DeviceNotAvailableException

clearLastConnectedWifiNetwork

public void clearLastConnectedWifiNetwork ()

clearLogcat

public void clearLogcat ()

connectToWifiNetwork

public boolean connectToWifiNetwork (String wifiSsid, 
                String wifiPsk)

매개 변수
wifiSsid String

wifiPsk String

보고
boolean

던짐
DeviceNotAvailableException

connectToWifiNetwork

public boolean connectToWifiNetwork (String wifiSsid, 
                String wifiPsk, 
                boolean scanSsid)

매개 변수
wifiSsid String

wifiPsk String

scanSsid boolean

보고
boolean

던짐
DeviceNotAvailableException

connectToWifiNetworkIfNeeded

public boolean connectToWifiNetworkIfNeeded (String wifiSsid, 
                String wifiPsk, 
                boolean scanSsid)

매개 변수
wifiSsid String

wifiPsk String

scanSsid boolean

보고
boolean

던짐
DeviceNotAvailableException

connectToWifiNetworkIfNeeded

public boolean connectToWifiNetworkIfNeeded (String wifiSsid, 
                String wifiPsk)

매개 변수
wifiSsid String

wifiPsk String

보고
boolean

던짐
DeviceNotAvailableException

createUser

public int createUser (String name, 
                boolean guest, 
                boolean ephemeral)

매개 변수
name String

guest boolean

ephemeral boolean

보고
int

던짐
DeviceNotAvailableException

createUser

public int createUser (String name)

매개 변수
name String

보고
int

던짐
DeviceNotAvailableException

createUserNoThrow

public int createUserNoThrow (String name)

매개 변수
name String

보고
int

던짐
DeviceNotAvailableException

deleteFile

public void deleteFile (String deviceFilePath)

매개 변수
deviceFilePath String

던짐
DeviceNotAvailableException

deviceSoftRestarted

public boolean deviceSoftRestarted (ProcessInfo prevSystemServerProcess)

매개 변수
prevSystemServerProcess ProcessInfo

보고
boolean

던짐
DeviceNotAvailableException

deviceSoftRestartedSince

public boolean deviceSoftRestartedSince (long utcEpochTime, 
                TimeUnit timeUnit)

매개 변수
utcEpochTime long

timeUnit TimeUnit

보고
boolean

던짐
DeviceNotAvailableException

disableAdbRoot

public boolean disableAdbRoot ()

보고
boolean

던짐
DeviceNotAvailableException

disableKeyguard

public void disableKeyguard ()

던짐
DeviceNotAvailableException

disableNetworkMonitor

public boolean disableNetworkMonitor ()

보고
boolean

던짐
DeviceNotAvailableException

disconnectFromWifi

public boolean disconnectFromWifi ()

보고
boolean

던짐
DeviceNotAvailableException

doesFileExist

public boolean doesFileExist (String deviceFilePath)

매개 변수
deviceFilePath String

보고
boolean

던짐
DeviceNotAvailableException

dumpHeap

public File dumpHeap (String process, 
                String devicePath)

매개 변수
process String

devicePath String

보고
File

던짐
DeviceNotAvailableException

enableAdbRoot

public boolean enableAdbRoot ()

보고
boolean

던짐
DeviceNotAvailableException

enableNetworkMonitor

public boolean enableNetworkMonitor ()

보고
boolean

던짐
DeviceNotAvailableException

encryptDevice

public boolean encryptDevice (boolean inplace)

매개 변수
inplace boolean

보고
boolean

던짐
DeviceNotAvailableException

executeAdbCommand

public String executeAdbCommand (long timeout, 
                String... cmdArgs)

매개 변수
timeout long

cmdArgs String

보고
String

던짐
DeviceNotAvailableException

executeAdbCommand

public String executeAdbCommand (String... cmdArgs)

매개 변수
cmdArgs String

보고
String

던짐
DeviceNotAvailableException

executeFastbootCommand

public CommandResult executeFastbootCommand (String... cmdArgs)

매개 변수
cmdArgs String

보고
CommandResult

던짐
DeviceNotAvailableException

executeFastbootCommand

public CommandResult executeFastbootCommand (long timeout, 
                String... cmdArgs)

매개 변수
timeout long

cmdArgs String

보고
CommandResult

던짐
DeviceNotAvailableException

executeLongFastbootCommand

public CommandResult executeLongFastbootCommand (String... cmdArgs)

매개 변수
cmdArgs String

보고
CommandResult

던짐
DeviceNotAvailableException

executeShellCommand

public String executeShellCommand (String command)

매개 변수
command String

보고
String

던짐
DeviceNotAvailableException

executeShellCommand

public void executeShellCommand (String command, 
                IShellOutputReceiver receiver, 
                long maxTimeToOutputShellResponse, 
                TimeUnit timeUnit, 
                int retryAttempts)

매개 변수
command String

receiver IShellOutputReceiver

maxTimeToOutputShellResponse long

timeUnit TimeUnit

retryAttempts int

던짐
DeviceNotAvailableException

executeShellCommand

public void executeShellCommand (String command, 
                IShellOutputReceiver receiver, 
                long maxTimeoutForCommand, 
                long maxTimeToOutputShellResponse, 
                TimeUnit timeUnit, 
                int retryAttempts)

매개 변수
command String

receiver IShellOutputReceiver

maxTimeoutForCommand long

maxTimeToOutputShellResponse long

timeUnit TimeUnit

retryAttempts int

던짐
DeviceNotAvailableException

executeShellCommand

public void executeShellCommand (String command, 
                IShellOutputReceiver receiver)

매개 변수
command String

receiver IShellOutputReceiver

던짐
DeviceNotAvailableException

executeShellV2Command

public CommandResult executeShellV2Command (String cmd)

매개 변수
cmd String

보고
CommandResult

던짐
DeviceNotAvailableException

executeShellV2Command

public CommandResult executeShellV2Command (String cmd, 
                OutputStream pipeToOutput)

매개 변수
cmd String

pipeToOutput OutputStream

보고
CommandResult

던짐
DeviceNotAvailableException

executeShellV2Command

public CommandResult executeShellV2Command (String cmd, 
                File pipeAsInput)

매개 변수
cmd String

pipeAsInput File

보고
CommandResult

던짐
DeviceNotAvailableException

executeShellV2Command

public CommandResult executeShellV2Command (String cmd, 
                long maxTimeoutForCommand, 
                TimeUnit timeUnit, 
                int retryAttempts)

매개 변수
cmd String

maxTimeoutForCommand long

timeUnit TimeUnit

retryAttempts int

보고
CommandResult

던짐
DeviceNotAvailableException

executeShellV2Command

public CommandResult executeShellV2Command (String cmd, 
                long maxTimeoutForCommand, 
                TimeUnit timeUnit)

매개 변수
cmd String

maxTimeoutForCommand long

timeUnit TimeUnit

보고
CommandResult

던짐
DeviceNotAvailableException

executeShellV2Command

public CommandResult executeShellV2Command (String cmd, 
                File pipeAsInput, 
                OutputStream pipeToOutput, 
                long maxTimeoutForCommand, 
                TimeUnit timeUnit, 
                int retryAttempts)

매개 변수
cmd String

pipeAsInput File

pipeToOutput OutputStream

maxTimeoutForCommand long

timeUnit TimeUnit

retryAttempts int

보고
CommandResult

던짐
DeviceNotAvailableException

fastbootWipePartition

public CommandResult fastbootWipePartition (String partition)

매개 변수
partition String

보고
CommandResult

던짐
DeviceNotAvailableException

getActiveApexes

public  getActiveApexes ()

보고

던짐
DeviceNotAvailableException

getAllSettings

public  getAllSettings (String namespace)

매개 변수
namespace String

보고

던짐
DeviceNotAvailableException

getAllocationState

public DeviceAllocationState getAllocationState ()

보고
DeviceAllocationState

getAndroidId

public String getAndroidId (int userId)

매개 변수
userId int

보고
String

던짐
DeviceNotAvailableException

getAndroidIds

public  getAndroidIds ()

보고

던짐
DeviceNotAvailableException

getApiLevel

public int getApiLevel ()

보고
int

던짐
DeviceNotAvailableException

getAppPackageInfo

public PackageInfo getAppPackageInfo (String packageName)

매개 변수
packageName String

보고
PackageInfo

던짐
DeviceNotAvailableException

getAppPackageInfos

public  getAppPackageInfos ()

보고

던짐
DeviceNotAvailableException

getBasebandVersion

public String getBasebandVersion ()

보고
String

던짐
DeviceNotAvailableException

getBattery

public Integer getBattery ()

보고
Integer

getBooleanProperty

public boolean getBooleanProperty (String name, 
                boolean defaultValue)

매개 변수
name String

defaultValue boolean

보고
boolean

던짐
DeviceNotAvailableException

getBootHistory

public  getBootHistory ()

보고

던짐
DeviceNotAvailableException

getBootHistorySince

public  getBootHistorySince (long utcEpochTime, 
                TimeUnit timeUnit)

매개 변수
utcEpochTime long

timeUnit TimeUnit

보고

던짐
DeviceNotAvailableException

getBootloaderVersion

public String getBootloaderVersion ()

보고
String

던짐
DeviceNotAvailableException

getBugreport

public InputStreamSource getBugreport ()

보고
InputStreamSource

getBugreportz

public InputStreamSource getBugreportz ()

보고
InputStreamSource

getBuildAlias

public String getBuildAlias ()

보고
String

던짐
DeviceNotAvailableException

getBuildFlavor

public String getBuildFlavor ()

보고
String

던짐
DeviceNotAvailableException

getBuildId

public String getBuildId ()

보고
String

던짐
DeviceNotAvailableException

getBuildSigningKeys

public String getBuildSigningKeys ()

보고
String

던짐
DeviceNotAvailableException

getCachedDeviceDescriptor

public DeviceDescriptor getCachedDeviceDescriptor ()

보고
DeviceDescriptor

getChildren

public String[] getChildren (String path)

매개 변수
path String

보고
String[]

던짐
DeviceNotAvailableException

getCurrentUser

public int getCurrentUser ()

보고
int

던짐
DeviceNotAvailableException

getDeviceClass

public String getDeviceClass ()

보고
String

getDeviceDate

public long getDeviceDate ()

보고
long

던짐
DeviceNotAvailableException

getDeviceDescriptor

public DeviceDescriptor getDeviceDescriptor ()

보고
DeviceDescriptor

getDeviceState

public TestDeviceState getDeviceState ()

보고
TestDeviceState

getDeviceTimeOffset

public long getDeviceTimeOffset (Date date)

매개 변수
date Date

보고
long

던짐
DeviceNotAvailableException

getEmulatorOutput

public InputStreamSource getEmulatorOutput ()

보고
InputStreamSource

getEmulatorProcess

public Process getEmulatorProcess ()

보고
Process

getExecuteShellCommandLog

public final File getExecuteShellCommandLog ()

모든 executeShellCommand(String) 로그를 포함하는 로그입니다.

보고
File

getExternalStoreFreeSpace

public long getExternalStoreFreeSpace ()

보고
long

던짐
DeviceNotAvailableException

getFastbootPath

public String getFastbootPath ()

보고
String

getFastbootProductType

public String getFastbootProductType ()

보고
String

던짐
DeviceNotAvailableException

getFastbootProductVariant

public String getFastbootProductVariant ()

보고
String

던짐
DeviceNotAvailableException

getFastbootVariable

public String getFastbootVariable (String variableName)

매개 변수
variableName String

보고
String

던짐
DeviceNotAvailableException

getFastbootVersion

public String getFastbootVersion ()

보고
String

getFileEntry

public IFileEntry getFileEntry (String path)

매개 변수
path String

보고
IFileEntry

던짐
DeviceNotAvailableException

getFileEntry

public IFileEntry getFileEntry (FileListingService.FileEntry entry)

루트가 아닌 경로에서 FileEntry 를 가져 오는 비공식 도우미입니다. FIXME : 모든 경로에서 사용할 수 있도록 FileEntry 시스템을 리팩터링합니다. (루트가 아닌 경우에도).

매개 변수
entry FileListingService.FileEntry : FileEntry 필요한만큼 FileEntry는 반드시 루트가 아닙니다.

보고
IFileEntry FileEntryWrapper 나타내는 FileEntryWrapper

던짐
DeviceNotAvailableException

getIDevice

public IDevice getIDevice ()

보고
IDevice

getInstalledPackageNames

public  getInstalledPackageNames ()

보고

던짐
DeviceNotAvailableException

getIntProperty

public long getIntProperty (String name, 
                long defaultValue)

매개 변수
name String

defaultValue long

보고
long

던짐
DeviceNotAvailableException

getIpAddress

public String getIpAddress ()

보고
String

던짐
DeviceNotAvailableException

getKeyguardState

public KeyguardControllerState getKeyguardState ()

보고
KeyguardControllerState

던짐
DeviceNotAvailableException

getLastExpectedRebootTimeMillis

public long getLastExpectedRebootTimeMillis ()

보고
long

getLaunchApiLevel

public int getLaunchApiLevel ()

보고
int

던짐
DeviceNotAvailableException

getLogcat

public InputStreamSource getLogcat ()

보고
InputStreamSource

getLogcat

public InputStreamSource getLogcat (int maxBytes)

매개 변수
maxBytes int

보고
InputStreamSource

getLogcatDump

public InputStreamSource getLogcatDump ()

보고
InputStreamSource

getLogcatSince

public InputStreamSource getLogcatSince (long date)

매개 변수
date long

보고
InputStreamSource

getMacAddress

public String getMacAddress ()

보고
String

getMaxNumberOfRunningUsersSupported

04 배 3400

보고
int

던짐
DeviceNotAvailableException

getMaxNumberOfUsersSupported

public int getMaxNumberOfUsersSupported ()

보고
int

던짐
DeviceNotAvailableException

getMonitor

public IDeviceStateMonitor getMonitor ()

보고
IDeviceStateMonitor

getMountPoint

public String getMountPoint (String mountName)

매개 변수
mountName String

보고
String

getMountPointInfo

public ITestDevice.MountPointInfo getMountPointInfo (String mountpoint)

매개 변수
mountpoint String

보고
ITestDevice.MountPointInfo

던짐
DeviceNotAvailableException

getMountPointInfo

public  getMountPointInfo ()

보고

던짐
DeviceNotAvailableException

getOptions

public TestDeviceOptions getOptions ()

보고
TestDeviceOptions

getPartitionFreeSpace

public long getPartitionFreeSpace (String partition)

매개 변수
partition String

보고
long

던짐
DeviceNotAvailableException

getPrimaryUserId

public Integer getPrimaryUserId ()

보고
Integer

던짐
DeviceNotAvailableException

getProcessByName

public ProcessInfo getProcessByName (String processName)

매개 변수
processName String

보고
ProcessInfo

던짐
DeviceNotAvailableException

getProcessPid

public String getProcessPid (String process)

매개 변수
process String

보고
String

던짐
DeviceNotAvailableException

getProductType

public String getProductType ()

보고
String

던짐
DeviceNotAvailableException

getProductVariant

public String getProductVariant ()

보고
String

던짐
DeviceNotAvailableException

getProperty

public String getProperty (String name)

매개 변수
name String

보고
String

던짐
DeviceNotAvailableException

getRecoveryMode

public ITestDevice.RecoveryMode getRecoveryMode ()

보고
ITestDevice.RecoveryMode

getScreenshot

public InputStreamSource getScreenshot (String format)

매개 변수
format String

보고
InputStreamSource

던짐
DeviceNotAvailableException

getScreenshot

public InputStreamSource getScreenshot (long displayId)

매개 변수
displayId long

보고
InputStreamSource

던짐
DeviceNotAvailableException

getScreenshot

public InputStreamSource getScreenshot (String format, 
                boolean rescale)

매개 변수
format String

rescale boolean

보고
InputStreamSource

던짐
DeviceNotAvailableException

getScreenshot

public InputStreamSource getScreenshot ()

보고
InputStreamSource

던짐
DeviceNotAvailableException

getSerialNumber

public String getSerialNumber ()

보고
String

getSetting

public String getSetting (int userId, 
                String namespace, 
                String key)

매개 변수
userId int

namespace String

key String

보고
String

던짐
DeviceNotAvailableException

getSetting

public String getSetting (String namespace, 
                String key)

매개 변수
namespace String

key String

보고
String

던짐
DeviceNotAvailableException

getSimOperator

public String getSimOperator ()

보고
String

getSimState

public String getSimState ()

보고
String

getTombstones

public  getTombstones ()

보고

던짐
DeviceNotAvailableException

getTotalMemory

public long getTotalMemory ()

보고
long

getUninstallablePackageNames

public  getUninstallablePackageNames ()

보고

던짐
DeviceNotAvailableException

getUseFastbootErase

public boolean getUseFastbootErase ()

보고
boolean

getUserFlags

public int getUserFlags (int userId)

매개 변수
userId int

보고
int

던짐
DeviceNotAvailableException

getUserInfos

public  getUserInfos ()

보고

던짐
DeviceNotAvailableException

getUserSerialNumber

public int getUserSerialNumber (int userId)

매개 변수
userId int

보고
int

던짐
DeviceNotAvailableException

handleAllocationEvent

public IManagedTestDevice.DeviceEventResponse handleAllocationEvent (DeviceEvent event)

이 장치를 새 할당 상태로 전환하거나 전환하지 않을 수있는 DeviceEvent를 처리합니다.

매개 변수
event DeviceEvent

보고
IManagedTestDevice.DeviceEventResponse

hasFeature

public boolean hasFeature (String feature)

매개 변수
feature String

보고
boolean

던짐
DeviceNotAvailableException

installPackage

public String installPackage (File packageFile, 
                boolean reinstall, 
                String... extraArgs)

매개 변수
packageFile File

reinstall boolean

extraArgs String

보고
String

던짐
DeviceNotAvailableException

installPackage

public String installPackage (File packageFile, 
                boolean reinstall, 
                boolean grantPermissions, 
                String... extraArgs)

매개 변수
packageFile File

reinstall boolean

grantPermissions boolean

extraArgs String

보고
String

던짐
DeviceNotAvailableException

installPackageForUser

public String installPackageForUser (File packageFile, 
                boolean reinstall, 
                int userId, 
                String... extraArgs)

매개 변수
packageFile File

reinstall boolean

userId int

extraArgs String

보고
String

던짐
DeviceNotAvailableException

installPackageForUser

public String installPackageForUser (File packageFile, 
                boolean reinstall, 
                boolean grantPermissions, 
                int userId, 
                String... extraArgs)

매개 변수
packageFile File

reinstall boolean

grantPermissions boolean

userId int

extraArgs String

보고
String

던짐
DeviceNotAvailableException

isAdbRoot

public boolean isAdbRoot ()

보고
boolean

던짐
DeviceNotAvailableException

isAdbTcp

public boolean isAdbTcp ()

보고
boolean

isAppEnumerationSupported

public boolean isAppEnumerationSupported ()

보고
boolean

던짐
DeviceNotAvailableException

isDeviceEncrypted

public boolean isDeviceEncrypted ()

보고
boolean

던짐
DeviceNotAvailableException

isDirectory

public boolean isDirectory (String path)

매개 변수
path String

보고
boolean

던짐
DeviceNotAvailableException

isEnableAdbRoot

public boolean isEnableAdbRoot ()

보고
boolean 기기에서 adb 루트를 활성화해야하는 경우 true

isEncryptionSupported

public boolean isEncryptionSupported ()

보고
boolean

던짐
DeviceNotAvailableException

isExecutable

public boolean isExecutable (String fullPath)

매개 변수
fullPath String

보고
boolean

던짐
DeviceNotAvailableException

isFastbootEnabled

public boolean isFastbootEnabled ()

보고
boolean

isHeadless

public boolean isHeadless ()

보고
boolean

던짐
DeviceNotAvailableException

isMultiUserSupported

public boolean isMultiUserSupported ()

보고
boolean

던짐
DeviceNotAvailableException

isPackageInstalled

public boolean isPackageInstalled (String packageName, 
                String userId)

매개 변수
packageName String

userId String

보고
boolean

던짐
DeviceNotAvailableException

isPackageInstalled

public boolean isPackageInstalled (String packageName)

매개 변수
packageName String

보고
boolean

던짐
DeviceNotAvailableException

isRuntimePermissionSupported

public boolean isRuntimePermissionSupported ()

보고
boolean

던짐
DeviceNotAvailableException

isStateBootloaderOrFastbootd

public boolean isStateBootloaderOrFastbootd ()

보고
boolean

isUserRunning

public boolean isUserRunning (int userId)

매개 변수
userId int

보고
boolean

던짐
DeviceNotAvailableException

isUserSecondary

public boolean isUserSecondary (int userId)

매개 변수
userId int

보고
boolean

던짐
DeviceNotAvailableException

isWifiEnabled

public boolean isWifiEnabled ()

보고
boolean

던짐
DeviceNotAvailableException

listDisplayIds

public  listDisplayIds ()

보고

던짐
DeviceNotAvailableException

listUsers

public  listUsers ()

보고

던짐
DeviceNotAvailableException

logBugreport

public boolean logBugreport (String dataName, 
                ITestLogger listener)

매개 변수
dataName String

listener ITestLogger

보고
boolean

logOnDevice

public void logOnDevice (String tag, 
                Log.LogLevel level, 
                String format, 
                Object... args)

매개 변수
tag String

level Log.LogLevel

format String

args Object

nonBlockingReboot

public void nonBlockingReboot ()

던짐
DeviceNotAvailableException

postAdbRootAction

public void postAdbRootAction ()

adb root 이후와 기기가 다시 온라인 상태가되기 전에 기기에 특정 작업을 수행해야하는 경우 재정의합니다. 기본 구현에는 추가 작업이 포함되지 않습니다. adb root는이 단계에서 활성화되지 않을 수 있습니다.

던짐
DeviceNotAvailableException

postAdbUnrootAction

public void postAdbUnrootAction ()

adb unroot 후 기기가 다시 온라인 상태가되기 전에 기기에 특정 작업을 수행해야하는 경우 재정의합니다. 기본 구현에는 추가 작업이 포함되지 않습니다. adb root는이 단계에서 비활성화되지 않을 수도 있습니다.

던짐
DeviceNotAvailableException

postBootSetup

public void postBootSetup ()

던짐
DeviceNotAvailableException

postInvocationTearDown

public void postInvocationTearDown (Throwable exception)

매개 변수
exception Throwable

preInvocationSetup

public void preInvocationSetup (IBuildInfo info)

매개 변수
info IBuildInfo

던짐
DeviceNotAvailableException
TargetSetupError

pullDir

public boolean pullDir (String deviceFilePath, 
                File localDir)

매개 변수
deviceFilePath String

localDir File

보고
boolean

던짐
DeviceNotAvailableException

pullFile

public boolean pullFile (String remoteFilePath, 
                File localFile)

매개 변수
remoteFilePath String

localFile File

보고
boolean

던짐
DeviceNotAvailableException

pullFile

public File pullFile (String remoteFilePath)

매개 변수
remoteFilePath String

보고
File

던짐
DeviceNotAvailableException

pullFileContents

public String pullFileContents (String remoteFilePath)

매개 변수
remoteFilePath String

보고
String

던짐
DeviceNotAvailableException

pullFileFromExternal

public File pullFileFromExternal (String remoteFilePath)

매개 변수
remoteFilePath String

보고
File

던짐
DeviceNotAvailableException

pushDir

public boolean pushDir (File localFileDir, 
                String deviceFilePath, 
                 excludedDirectories)

매개 변수
localFileDir File

deviceFilePath String

excludedDirectories

보고
boolean

던짐
DeviceNotAvailableException

pushDir

public boolean pushDir (File localFileDir, 
                String deviceFilePath)

매개 변수
localFileDir File

deviceFilePath String

보고
boolean

던짐
DeviceNotAvailableException

pushFile

public boolean pushFile (File localFile, 
                String remoteFilePath)

매개 변수
localFile File

remoteFilePath String

보고
boolean

던짐
DeviceNotAvailableException

pushString

public boolean pushString (String contents, 
                String remoteFilePath)

매개 변수
contents String

remoteFilePath String

보고
boolean

던짐
DeviceNotAvailableException

재부팅

public void reboot (String reason)

매개 변수
reason String

던짐
DeviceNotAvailableException

재부팅

public void reboot ()

던짐
DeviceNotAvailableException

rebootIntoBootloader

public void rebootIntoBootloader ()

던짐
DeviceNotAvailableException

rebootIntoFastbootd

public void rebootIntoFastbootd ()

던짐
DeviceNotAvailableException

rebootIntoRecovery

public void rebootIntoRecovery ()

던짐
DeviceNotAvailableException

rebootIntoSideload

public void rebootIntoSideload ()

던짐
DeviceNotAvailableException

rebootIntoSideload

public void rebootIntoSideload (boolean autoReboot)

매개 변수
autoReboot boolean

던짐
DeviceNotAvailableException

rebootUntilOnline

public void rebootUntilOnline ()

던짐
DeviceNotAvailableException

rebootUntilOnline

public void rebootUntilOnline (String reason)

매개 변수
reason String

던짐
DeviceNotAvailableException

rebootUserspace

public void rebootUserspace ()

던짐
DeviceNotAvailableException

rebootUserspaceUntilOnline

public void rebootUserspaceUntilOnline ()

던짐
DeviceNotAvailableException

recoverDevice

public void recoverDevice ()

장치 통신 복구를 시도합니다.

던짐
DeviceNotAvailableException 장치를 더 이상 사용할 수없는 경우

remountSystemWritable

public void remountSystemWritable ()

던짐
DeviceNotAvailableException

remountVendorWritable

public void remountVendorWritable ()

던짐
DeviceNotAvailableException

removeAdmin

public boolean removeAdmin (String componentName, 
                int userId)

매개 변수
componentName String

userId int

보고
boolean

던짐
DeviceNotAvailableException

removeOwners

public void removeOwners ()

던짐
DeviceNotAvailableException

removeUser

public boolean removeUser (int userId)

매개 변수
userId int

보고
boolean

던짐
DeviceNotAvailableException

runInstrumentationTests

public boolean runInstrumentationTests (IRemoteAndroidTestRunner runner, 
                ITestLifeCycleReceiver... listeners)

매개 변수
runner IRemoteAndroidTestRunner

listeners ITestLifeCycleReceiver

보고
boolean

던짐
DeviceNotAvailableException

runInstrumentationTests

public boolean runInstrumentationTests (IRemoteAndroidTestRunner runner, 
                 listeners)

매개 변수
runner IRemoteAndroidTestRunner

listeners

보고
boolean

던짐
DeviceNotAvailableException

runInstrumentationTestsAsUser

public boolean runInstrumentationTestsAsUser (IRemoteAndroidTestRunner runner, 
                int userId, 
                ITestLifeCycleReceiver... listeners)

매개 변수
runner IRemoteAndroidTestRunner

userId int

listeners ITestLifeCycleReceiver

보고
boolean

던짐
DeviceNotAvailableException

runInstrumentationTestsAsUser

public boolean runInstrumentationTestsAsUser (IRemoteAndroidTestRunner runner, 
                int userId, 
                 listeners)

매개 변수
runner IRemoteAndroidTestRunner

userId int

listeners

보고
boolean

던짐
DeviceNotAvailableException

setDate

public void setDate (Date date)

매개 변수
date Date

던짐
DeviceNotAvailableException

setDeviceOwner

public boolean setDeviceOwner (String componentName, 
                int userId)

매개 변수
componentName String

userId int

보고
boolean

던짐
DeviceNotAvailableException

setDeviceState

public void setDeviceState (TestDeviceState deviceState)

매개 변수
deviceState TestDeviceState

setEmulatorOutputStream

public void setEmulatorOutputStream (SizeLimitedOutputStream output)

에뮬레이터의 경우 SizeLimitedOutputStream 을 로그 출력으로 설정합니다.

매개 변수
output SizeLimitedOutputStream : 출력 기록

setEmulatorProcess

public void setEmulatorProcess (Process p)

매개 변수
p Process

setFastbootEnabled

public void setFastbootEnabled (boolean fastbootEnabled)

매개 변수
fastbootEnabled boolean

setFastbootPath

public void setFastbootPath (String fastbootPath)

매개 변수
fastbootPath String

setIDevice

public void setIDevice (IDevice newDevice)

매개 변수
newDevice IDevice

setOptions

public void setOptions (TestDeviceOptions options)

매개 변수
options TestDeviceOptions

setProperty

public boolean setProperty (String propKey, 
                String propValue)

매개 변수
propKey String

propValue String

보고
boolean

던짐
DeviceNotAvailableException

setRecovery

public void setRecovery (IDeviceRecovery recovery)

매개 변수
recovery IDeviceRecovery

setRecoveryMode

public void setRecoveryMode (ITestDevice.RecoveryMode mode)

매개 변수
mode ITestDevice.RecoveryMode

setSetting

public void setSetting (String namespace, 
                String key, 
                String value)

매개 변수
namespace String

key String

value String

던짐
DeviceNotAvailableException

setSetting

public void setSetting (int userId, 
                String namespace, 
                String key, 
                String value)

매개 변수
userId int

namespace String

key String

value String

던짐
DeviceNotAvailableException

setUseFastbootErase

public void setUseFastbootErase (boolean useFastbootErase)

매개 변수
useFastbootErase boolean

startLogcat

public void startLogcat ()

startUser

public boolean startUser (int userId)

매개 변수
userId int

보고
boolean

던짐
DeviceNotAvailableException

startUser

public boolean startUser (int userId, 
                boolean waitFlag)

매개 변수
userId int

waitFlag boolean

보고
boolean

던짐
DeviceNotAvailableException

stopEmulatorOutput

public void stopEmulatorOutput ()

stopLogcat

public void stopLogcat ()

stopUser

public boolean stopUser (int userId)

매개 변수
userId int

보고
boolean

던짐
DeviceNotAvailableException

stopUser

public boolean stopUser (int userId, 
                boolean waitFlag, 
                boolean forceFlag)

매개 변수
userId int

waitFlag boolean

forceFlag boolean

보고
boolean

던짐
DeviceNotAvailableException

switchToAdbTcp

public String switchToAdbTcp ()

보고
String

던짐
DeviceNotAvailableException

switchToAdbUsb

public boolean switchToAdbUsb ()

보고
boolean

던짐
DeviceNotAvailableException

switchUser

public boolean switchUser (int userId)

매개 변수
userId int

보고
boolean

던짐
DeviceNotAvailableException

switchUser

public boolean switchUser (int userId, 
                long timeout)

매개 변수
userId int

timeout long

보고
boolean

던짐
DeviceNotAvailableException

syncFiles

public boolean syncFiles (File localFileDir, 
                String deviceFilePath)

매개 변수
localFileDir File

deviceFilePath String

보고
boolean

던짐
DeviceNotAvailableException

takeBugreport

public Bugreport takeBugreport ()

보고
Bugreport

unencryptDevice

public boolean unencryptDevice ()

보고
boolean

던짐
DeviceNotAvailableException

uninstallPackage

public String uninstallPackage (String packageName)

매개 변수
packageName String

보고
String

던짐
DeviceNotAvailableException

unlockDevice

public boolean unlockDevice ()

보고
boolean

던짐
DeviceNotAvailableException

waitForBootComplete

public boolean waitForBootComplete (long timeOut)

매개 변수
timeOut long

보고
boolean

던짐
DeviceNotAvailableException

waitForDeviceAvailable

public void waitForDeviceAvailable ()

던짐
DeviceNotAvailableException

waitForDeviceAvailable

public void waitForDeviceAvailable (long waitTime)

매개 변수
waitTime long

던짐
DeviceNotAvailableException

waitForDeviceInRecovery

public boolean waitForDeviceInRecovery (long waitTime)

매개 변수
waitTime long

보고
boolean

waitForDeviceInSideload

public boolean waitForDeviceInSideload (long waitTime)

매개 변수
waitTime long

보고
boolean

waitForDeviceNotAvailable

public boolean waitForDeviceNotAvailable (long waitTime)

매개 변수
waitTime long

보고
boolean

waitForDeviceOnline

public void waitForDeviceOnline ()

던짐
DeviceNotAvailableException

waitForDeviceOnline

public void waitForDeviceOnline (long waitTime)

매개 변수
waitTime long

던짐
DeviceNotAvailableException

waitForDeviceShell

public boolean waitForDeviceShell (long waitTime)

매개 변수
waitTime long

보고
boolean

보호 된 방법

checkApiLevelAgainst

protected void checkApiLevelAgainst (String feature, 
                int strictMinLevel)

매개 변수
feature String

strictMinLevel int

createRebootDeviceAction

protected NativeDevice.RebootDeviceAction createRebootDeviceAction (NativeDevice.RebootMode rebootMode, 
                String reason)

재부팅 작업을 수행 할 때 사용할 RebootDeviceAction 을 만듭니다.

매개 변수
rebootMode NativeDevice.RebootMode :이 재부팅 모드입니다.

reason String :이 재부팅 용입니다.

보고
NativeDevice.RebootDeviceAction 생성 된 RebootDeviceAction .

doAdbReboot

protected void doAdbReboot (NativeDevice.RebootMode rebootMode, 
                String reason)

adb 재부팅을 수행합니다.

매개 변수
rebootMode NativeDevice.RebootMode :이 재부팅 모드입니다.

reason String :이 재부팅 용입니다.

던짐
DeviceNotAvailableException

ensureRuntimePermissionSupported

protected void ensureRuntimePermissionSupported ()

런타임 권한이 지원되지 않는 경우 예외를 throw하는 도우미 메서드

던짐
DeviceNotAvailableException

getBugreportInternal

protected InputStreamSource getBugreportInternal ()

보고
InputStreamSource

getBugreportzInternal

protected File getBugreportzInternal ()

bugreportz zip 파일을 ERROR(/File) 로 가져 오는 내부 도우미 메서드입니다.

보고
File

getRunUtil

protected IRunUtil getRunUtil ()

사용할 RunUtil 인스턴스를 RunUtil .

보고
IRunUtil

internalGetProperty

protected String internalGetProperty (String propName, 
                String fastbootVar, 
                String description)

기본적으로 ddmlib 캐시에서 장치 속성을 가져오고 장치가 Fastboot에 있는지 여부에 따라`adb shell getprop` 또는`fastboot getvar`로 폴백합니다.

매개 변수
propName String :`adb shell getprop`에서 반환 한 장치 속성의 이름

fastbootVar String : 쿼리 할 해당 fastboot 변수의 이름입니다. null 이면 빠른 부팅 쿼리가 시도되지 않습니다.

description String : 변수에 대한 간단한 설명입니다. 첫 글자는 대문자 여야합니다.

보고
String 주어진 속성의 값을 포함하는 문자열 ( null 이거나 비어있을 수 있음)

던짐
DeviceNotAvailableException

isNewer

protected boolean isNewer (File localFile, 
                IFileEntry entry)

로컬 파일이 원격 파일보다 새로운 경우 true 반환 true . IFileEntry 는 분 IFileEntry 까지 정확하며, 동일한 시간의 경우 파일이 더 새로운 것으로 간주됩니다.

매개 변수
localFile File

entry IFileEntry

보고
boolean

performDeviceAction

protected boolean performDeviceAction (String actionDescription, 
                com.android.tradefed.device.NativeDevice.DeviceAction action, 
                int retryAttempts)

이 장치에서 작업을 수행합니다. 장치 복구를 시도하고 조치가 실패하면 선택적으로 명령을 재 시도합니다.

매개 변수
actionDescription String : 수행 할 작업에 대한 간단한 설명입니다. 로깅 목적으로 만 사용됩니다.

action com.android.tradefed.device.NativeDevice.DeviceAction : 수행 할 작업

retryAttempts int : 실패했지만 복구가 성공한 경우 재 시도에서 작업을 시도합니다.

보고
boolean 작업이 성공적으로 수행 된 경우 true

던짐
DeviceNotAvailableException 복구 시도가 실패하거나 최대 시도가 성공하지 못한 경우

postAdbReboot

protected void postAdbReboot ()

재부팅 후 취할 수있는 가능한 추가 조치.

던짐
DeviceNotAvailableException

prePostBootSetup

protected void prePostBootSetup ()

각 기기 유형 (AndroidNativeDevice, TestDevice)이 특정 사후 부팅 설정에 대해이 메서드를 재정의하도록 허용합니다.

던짐
DeviceNotAvailableException

setClock

protected void setClock (Clock clock)

사용할 Clock 인스턴스를 설정합니다.

매개 변수
clock Clock

setLogStartDelay

protected void setLogStartDelay (int delay)

온라인 장치의 logcat 캡처를 시작하기 전에 대기 할 시간 (ms)을 설정합니다.

매개 변수
delay int : ms 단위의 지연

waitForDeviceNotAvailable

protected void waitForDeviceNotAvailable (String operationDesc, 
                long time)

매개 변수
operationDesc String

time long