AdbTcp연결

public class AdbTcpConnection
extends DefaultConnection

java.lang.객체
com.android.tradefed.device.connection.AbstractConnection
com.android.tradefed.device.connection.DefaultConnection
com.android.tradefed.device.connection.AdbTcpConnection


장치의 표준 adb 연결로 간주되는 장치의 기본 연결 표현입니다.

요약

상수

long DEFAULT_SHORT_CMD_TIMEOUT

int MAX_RETRIES

long RETRY_INTERVAL_MS

long WAIT_FOR_ADB_CONNECT

공개 생성자

AdbTcpConnection ( DefaultConnection.ConnectionBuilder builder)

공개 방법

boolean adbTcpConnect (String host, String port)

adb가 주어진 tcp ip Android 기기에 연결하는 도우미 메서드

boolean adbTcpDisconnect (String host, String port)

주어진 tcp ip Android 기기에서 adb 연결을 해제하는 도우미 메서드

String getHostName (String serial)

장치와 관련된 호스트 이름을 반환합니다.

String getPortNum (String serial)

장치와 관련된 포트 번호를 반환합니다.

void reconnect (String serial)

장치에 다시 연결하십시오.

void tearDownConnection ()

연결을 정리하십시오.

보호된 메서드

void waitForAdbConnect (String serial, long waitTime)

adb 연결이 활성화되어 있는지 확인하십시오.

상수

DEFAULT_SHORT_CMD_TIMEOUT

protected static final long DEFAULT_SHORT_CMD_TIMEOUT

상수 값: 20000(0x0000000000004e20)

MAX_RETRIES

protected static final int MAX_RETRIES

상수 값: 5(0x00000005)

RETRY_INTERVAL_MS

protected static final long RETRY_INTERVAL_MS

상수 값: 5000(0x0000000000001388)

WAIT_FOR_ADB_CONNECT

protected static final long WAIT_FOR_ADB_CONNECT

상수 값: 120000(0x000000000001d4c0)

공개 생성자

AdbTcp연결

public AdbTcpConnection (DefaultConnection.ConnectionBuilder builder)

매개변수
builder DefaultConnection.ConnectionBuilder

공개 방법

adbTcpConnect

public boolean adbTcpConnect (String host, 
                String port)

adb가 주어진 tcp ip Android 기기에 연결하는 도우미 메서드

매개변수
host String : tcp/ip Android 장치의 호스트 이름/ip

port String : tcp/ip 장치의 포트 번호

보고
boolean 장치에 성공적으로 연결되면 true이고 그렇지 않으면 false입니다.

adbTcpDisconnect

public boolean adbTcpDisconnect (String host, 
                String port)

주어진 tcp ip Android 기기에서 adb 연결을 해제하는 도우미 메서드

매개변수
host String : tcp/ip Android 장치의 호스트 이름/ip

port String : tcp/ip 장치의 포트 번호

보고
boolean 장치와의 연결이 성공적으로 끊어지면 true이고 그렇지 않으면 false입니다.

getHostName

public String getHostName (String serial)

장치와 관련된 호스트 이름을 반환합니다. 연재물에서 발췌했습니다.

매개변수
serial String

보고
String

getPortNum

public String getPortNum (String serial)

장치와 관련된 포트 번호를 반환합니다. 연재물에서 발췌했습니다.

매개변수
serial String

보고
String

다시 연결

public void reconnect (String serial)

장치에 다시 연결하십시오.

매개변수
serial String : 장치 일련 번호입니다.

던지기
DeviceNotAvailableException

tearDownConnection

public void tearDownConnection ()

연결을 정리하십시오.

보호된 메서드

waitForAdbConnect

protected void waitForAdbConnect (String serial, 
                long waitTime)

adb 연결이 활성화되어 있는지 확인하십시오.

매개변수
serial String

waitTime long

던지기
DeviceNotAvailableException