AdbSsh연결
public class AdbSshConnection
extends AdbTcpConnection
java.lang.Object | ||||
↳ | com.android.tradefed.device.connection.AbstractConnection | |||
↳ | com.android.tradefed.device.connection.DefaultConnection | |||
↳ | com.android.tradefed.device.connection.AdbTcpConnection | |||
↳ | com.android.tradefed.device.connection.AdbSshConnection |
SSH 브리지를 통한 Adb 연결.
요약
공개 생성자 | |
---|---|
AdbSshConnection ( DefaultConnection.ConnectionBuilder builder) |
공개 메소드 | |
---|---|
GceAvdInfo | getAvdInfo () 생성된 원격 VM에서 |
AbstractTunnelMonitor | getGceTunnelMonitor () 장치의 |
void | getSshBugreport () 장치에 직접 SSH를 연결하여 원격 버그 보고서를 캡처합니다. |
getTombstones () Cuttlefish에는 삭제 표시를 원격 호스트로 가져와서 직접 얻을 수 있는 특별한 기능이 있습니다. | |
void | initializeConnection () 장치 연결을 초기화합니다. |
void | notifyAdbRebootCalled () doAdbReboot가 호출되면 알립니다. |
CommandResult | powerwash () GCE 인스턴스 파워워시 시도 |
CommandResult | powerwashGce (String user, Integer offset) GCE 인스턴스 파워워시 시도 |
void | reconnect (String serial) 장치에 다시 연결하십시오. |
void | reconnectForRecovery (String serial) 복구 루틴을 위해 장치에 다시 연결하십시오. |
CommandResult | restoreSnapshotGce (String user, Integer offset, String snapshotId) Cuttlefish 인스턴스의 스냅샷 복원 시도 |
CommandResult | snapshotGce (String user, Integer offset, String snapshotId) Cuttlefish 인스턴스 스냅샷 시도 |
void | tearDownConnection () 연결을 정리하세요. |
보호된 방법 | |
---|---|
long | getCurrentTime () 현재 시스템 시간을 반환합니다. |
void | launchGce ( IBuildInfo buildInfo, MultiMap <String, String> attributes) 빌드 정보를 기반으로 실제 gce 장치를 실행합니다. |
void | waitForTunnelOnline (long waitTime) 터널 모니터가 실행 중인지 확인하세요. |
공개 생성자
AdbSsh연결
public AdbSshConnection (DefaultConnection.ConnectionBuilder builder)
매개변수 | |
---|---|
builder | DefaultConnection.ConnectionBuilder |
공개 메소드
getAvdInfo
public GceAvdInfo getAvdInfo ()
생성된 원격 VM에서 GceAvdInfo
반환합니다. 정보를 검사할 수 있도록 상태에 관계없이 반환됩니다.
보고 | |
---|---|
GceAvdInfo |
getGceTunnel모니터
public AbstractTunnelMonitor getGceTunnelMonitor ()
장치의 AbstractTunnelMonitor
반환합니다.
보고 | |
---|---|
AbstractTunnelMonitor |
getSsh버그 신고
public void getSshBugreport ()
장치에 직접 SSH를 연결하여 원격 버그 보고서를 캡처합니다.
getTombstones
publicgetTombstones ()
Cuttlefish에는 삭제 표시를 원격 호스트로 가져와서 직접 얻을 수 있는 특별한 기능이 있습니다.
보고 | |
---|---|
초기화연결
public void initializeConnection ()
장치 연결을 초기화합니다.
던지기 | |
---|---|
DeviceNotAvailableException | |
TargetSetupError |
통지AdbReboot호출됨
public void notifyAdbRebootCalled ()
doAdbReboot가 호출되면 알립니다.
파워워시
public CommandResult powerwash ()
GCE 인스턴스 파워워시 시도
보고 | |
---|---|
CommandResult | 파워워시 시도의 CommandResult를 반환합니다. |
던지기 | |
---|---|
| com.android.tradefed.targetprep.TargetSetupError |
TargetSetupError |
파워워시Gce
public CommandResult powerwashGce (String user, Integer offset)
GCE 인스턴스 파워워시 시도
매개변수 | |
---|---|
user | String : AVD 사용자를 실행하는 호스트, 해당되지 않는 경우 null . |
offset | Integer : 호스트에 있는 AVD의 장치 번호 오프셋, 해당되지 않는 경우 null |
보고 | |
---|---|
CommandResult | 파워워시 시도의 CommandResult를 반환합니다. |
던지기 | |
---|---|
| com.android.tradefed.targetprep.TargetSetupError |
TargetSetupError |
다시 연결하다
public void reconnect (String serial)
장치에 다시 연결하십시오.
매개변수 | |
---|---|
serial | String : 장치 일련 번호입니다. |
던지기 | |
---|---|
DeviceNotAvailableException |
복구를 위해 다시 연결
public void reconnectForRecovery (String serial)
복구 루틴을 위해 장치에 다시 연결하십시오.
매개변수 | |
---|---|
serial | String : 장치 일련 번호입니다. |
던지기 | |
---|---|
DeviceNotAvailableException |
복원스냅샷Gce
public CommandResult restoreSnapshotGce (String user, Integer offset, String snapshotId)
Cuttlefish 인스턴스의 스냅샷 복원 시도
매개변수 | |
---|---|
user | String : AVD 사용자를 실행하는 호스트, 해당되지 않는 경우 null . |
offset | Integer : 호스트에 있는 AVD의 장치 번호 오프셋, 해당되지 않는 경우 null |
snapshotId | String : 스냅샷 ID |
보고 | |
---|---|
CommandResult | 복원 스냅샷 시도의 CommandResult를 반환합니다. |
던지기 | |
---|---|
| com.android.tradefed.targetprep.TargetSetupError |
TargetSetupError |
snapshotGce
public CommandResult snapshotGce (String user, Integer offset, String snapshotId)
Cuttlefish 인스턴스 스냅샷 시도
매개변수 | |
---|---|
user | String : AVD 사용자를 실행하는 호스트, 해당되지 않는 경우 null . |
offset | Integer : 호스트에 있는 AVD의 장치 번호 오프셋, 해당되지 않는 경우 null |
snapshotId | String |
보고 | |
---|---|
CommandResult | 스냅샷 시도의 CommandResult를 반환합니다. |
던지기 | |
---|---|
| com.android.tradefed.targetprep.TargetSetupError |
TargetSetupError |
TearDownConnection
public void tearDownConnection ()
연결을 정리하세요.
보호된 방법
getCurrentTime
protected long getCurrentTime ()
현재 시스템 시간을 반환합니다. 테스트를 위해 노출되었습니다.
보고 | |
---|---|
long |
발사Gce
protected void launchGce (IBuildInfo buildInfo, MultiMap<String, String> attributes)
빌드 정보를 기반으로 실제 gce 장치를 실행합니다.
매개변수 | |
---|---|
buildInfo | IBuildInfo |
attributes | MultiMap |
던지기 | |
---|---|
TargetSetupError |
waitForTunnelOnline
protected void waitForTunnelOnline (long waitTime)
터널 모니터가 실행 중인지 확인하세요.
매개변수 | |
---|---|
waitTime | long |
던지기 | |
---|---|
DeviceNotAvailableException |