IDeviceSelection

public interface IDeviceSelection
implements IMatcher<IDevice>

com.android.tradefed.device.IDeviceSelection


Giao diện cho tiêu chí lựa chọn thiết bị.

Tóm tắt

Phương thức công khai

abstract boolean deviceRequested()
abstract boolean emulatorRequested()
abstract boolean gceDeviceRequested()
abstract IDeviceSelection.BaseDeviceType getBaseDeviceTypeRequested()

Trả về loại thiết bị mà chúng ta nên sử dụng.

abstract Integer getBatteryLevel(IDevice device)

Truy xuất mức pin của thiết bị đã cho

abstract String getDeviceProductType(IDevice device)

Lấy loại sản phẩm của thiết bị đã cho

abstract String getDeviceProductVariant(IDevice device)

Lấy biến thể sản phẩm của thiết bị đã cho

abstract Collection<String> getExcludeSerials()

Lấy bản sao của danh sách loại trừ số sê-ri

abstract Map<String, String> getNoMatchReason()

Trả về lý do thiết bị không khớp.

abstract Collection<String> getProductTypes()

Lấy bản sao của danh sách loại sản phẩm

abstract Map<String, String> getProperties()

Trả về bản đồ của danh sách tài sản

abstract Collection<String> getSerials(IDevice device)

Lấy bản sao của số sê-ri

abstract List<String> getSerials()

Trả về danh sách các số sê-ri được yêu cầu.

abstract boolean nullDeviceRequested()
abstract void setBaseDeviceTypeRequested(IDeviceSelection.BaseDeviceType type)

Đặt loại thiết bị mà chúng ta nên sử dụng.

abstract void setRequireBatteryCheck(boolean requireCheck)

Đặt xem chúng ta có muốn kiểm tra pin hay không.

abstract void setSerial(String... serialNumber)

Đặt danh sách số sê-ri được đưa vào, thay thế mọi giá trị hiện có.

abstract boolean shouldCreateTemporarilyPlaceholder()

Tạo một phần giữ chỗ tạm thời từ siêu dữ liệu.

abstract boolean stubEmulatorRequested()
default boolean tcpDeviceRequested()

Phương thức công khai

deviceRequested

public abstract boolean deviceRequested ()

Giá trị trả về
boolean true nếu có yêu cầu về thiết bị

emulatorRequested

public abstract boolean emulatorRequested ()

Giá trị trả về
boolean true nếu có yêu cầu về trình mô phỏng

gceDeviceRequested

public abstract boolean gceDeviceRequested ()

Giá trị trả về
boolean true nếu một thiết bị gce (còn gọi là thiết bị từ xa) đã được yêu cầu

getBaseDeviceTypeRequested

public abstract IDeviceSelection.BaseDeviceType getBaseDeviceTypeRequested ()

Trả về loại thiết bị mà chúng ta nên sử dụng.

Giá trị trả về
IDeviceSelection.BaseDeviceType

getBatteryLevel

public abstract Integer getBatteryLevel (IDevice device)

Truy xuất mức pin của thiết bị đã cho

Tham số
device IDevice: IDevice

Giá trị trả về
Integer mức pin của thiết bị hoặc null nếu không xác định được

getDeviceProductType

public abstract String getDeviceProductType (IDevice device)

Lấy loại sản phẩm của thiết bị đã cho

Tham số
device IDevice: IDevice

Giá trị trả về
String loại sản phẩm của thiết bị hoặc null nếu không xác định được

getDeviceProductVariant

public abstract String getDeviceProductVariant (IDevice device)

Lấy biến thể sản phẩm của thiết bị đã cho

Tham số
device IDevice: IDevice

Giá trị trả về
String biến thể sản phẩm của thiết bị hoặc null nếu không xác định được

getExcludeSerials

public abstract Collection<String> getExcludeSerials ()

Lấy bản sao của danh sách loại trừ số sê-ri

Giá trị trả về
Collection<String> Collection số sê-ri

getNoMatchReason

public abstract Map<String, String> getNoMatchReason ()

Trả về lý do thiết bị không khớp.

Giá trị trả về
Map<String, String> Map số sê-ri đến lý do không được phân bổ

getProductTypes

public abstract Collection<String> getProductTypes ()

Lấy bản sao của danh sách loại sản phẩm

Giá trị trả về
Collection<String> Collection loại sản phẩm

getProperties

public abstract Map<String, String> getProperties ()

Trả về bản đồ của danh sách tài sản

Giá trị trả về
Map<String, String> Map tên thuộc tính thiết bị thành các giá trị

getSerials

public abstract Collection<String> getSerials (IDevice device)

Lấy bản sao của số sê-ri

Tham số
device IDevice: IDevice đại diện cho thiết bị được xem xét để lựa chọn.

Giá trị trả về
Collection<String> Collection số sê-ri

getSerials

public abstract List<String> getSerials ()

Trả về danh sách các số sê-ri được yêu cầu.

Giá trị trả về
List<String>

nullDeviceRequested

public abstract boolean nullDeviceRequested ()

Giá trị trả về
boolean true nếu bạn đã yêu cầu một thiết bị rỗng (tức là không yêu cầu thiết bị)

setBaseDeviceTypeRequested

public abstract void setBaseDeviceTypeRequested (IDeviceSelection.BaseDeviceType type)

Đặt loại thiết bị mà chúng ta nên sử dụng.

Tham số
type IDeviceSelection.BaseDeviceType

setRequireBatteryCheck

public abstract void setRequireBatteryCheck (boolean requireCheck)

Đặt xem chúng ta có muốn kiểm tra pin hay không.

Tham số
requireCheck boolean

setSerial

public abstract void setSerial (String... serialNumber)

Đặt danh sách số sê-ri được đưa vào, thay thế mọi giá trị hiện có.

Tham số
serialNumber String

shouldCreateTemporarilyPlaceholder

public abstract boolean shouldCreateTemporarilyPlaceholder ()

Tạo một phần giữ chỗ tạm thời từ siêu dữ liệu.

Giá trị trả về
boolean

stubEmulatorRequested

public abstract boolean stubEmulatorRequested ()

Giá trị trả về
boolean true nếu đã yêu cầu trình mô phỏng stub. Trình mô phỏng gốc là một phần giữ chỗ sẽ được dùng khi cấu hình phải khởi chạy một trình mô phỏng.

tcpDeviceRequested

public boolean tcpDeviceRequested ()

Giá trị trả về
boolean true nếu một thiết bị tcp (còn gọi là thiết bị đã kết nối adb) đã được yêu cầu