CuttlefishDisplayHandler

public class CuttlefishDisplayHandler
extends Object

java.lang.Object
com.android.tradefed.device.internal.CuttlefishDisplayHandler


ยูทิลิตีที่จัดการคำขอการแสดงผลของ Cuttlefish ซึ่งมีไว้เพื่อใช้ภายในผ่าน การทดสอบโฮสต์เฉพาะของ Cuttlefish เท่านั้น

สรุป

คลาสที่ซ้อนกัน

class CuttlefishDisplayHandler.Display

 

เครื่องมือสร้างสาธารณะ

CuttlefishDisplayHandler()

เมธอดสาธารณะ

int addDisplay(ITestDevice device, int width, int height, int dpi, int refreshRateHz)

เรียกใช้ `cvd display add ` สำหรับอุปกรณ์ Cuttlefish ที่ระบุ

Map<Integer, CuttlefishDisplayHandler.Display> listDisplays(ITestDevice device)

เรียกใช้ `cvd display list` สำหรับอุปกรณ์ Cuttlefish ที่ระบุ

void removeDisplay(ITestDevice device, int displayNumber)

เรียกใช้ `cvd display remove --display=` สำหรับอุปกรณ์ Cuttlefish ที่ระบุ

BufferedImage screenshotDisplay(ITestDevice device, int displayNumber)

เรียกใช้ `cvd display screenshot --display=` สำหรับอุปกรณ์ Cuttlefish ที่ระบุ

เครื่องมือสร้างสาธารณะ

CuttlefishDisplayHandler

public CuttlefishDisplayHandler ()

เมธอดสาธารณะ

addDisplay

public int addDisplay (ITestDevice device, 
                int width, 
                int height, 
                int dpi, 
                int refreshRateHz)

เรียกใช้ `cvd display add ` สำหรับอุปกรณ์ Cuttlefish ที่ระบุ

พารามิเตอร์
device ITestDevice: อุปกรณ์ที่จะใช้

width int: ความกว้างเป็นพิกเซลสำหรับการแสดงผลใหม่

height int: ความสูงเป็นพิกเซลสำหรับการแสดงผลใหม่

dpi int: dpi เป็นพิกเซลต่อนิ้วสำหรับการแสดงผลใหม่

refreshRateHz int: อัตรารีเฟรชเป็นเฮิรตซ์สำหรับการแสดงผลใหม่

การคืนสินค้า
int หมายเลขการแสดงผลของการแสดงผลที่เพิ่มใหม่ หากสำเร็จ

ส่ง
DeviceNotAvailableException

listDisplays

public Map<Integer, CuttlefishDisplayHandler.Display> listDisplays (ITestDevice device)

เรียกใช้ `cvd display list` สำหรับอุปกรณ์ Cuttlefish ที่ระบุ

พารามิเตอร์
device ITestDevice: อุปกรณ์ที่จะใช้

การคืนสินค้า
Map<Integer, CuttlefishDisplayHandler.Display>

ส่ง
DeviceNotAvailableException

removeDisplay

public void removeDisplay (ITestDevice device, 
                int displayNumber)

เรียกใช้ `cvd display remove --display=` สำหรับอุปกรณ์ Cuttlefish ที่ระบุ

พารามิเตอร์
device ITestDevice: อุปกรณ์ที่จะใช้

displayNumber int: การแสดงผลที่จะนำออก

ส่ง
DeviceNotAvailableException

screenshotDisplay

public BufferedImage screenshotDisplay (ITestDevice device, 
                int displayNumber)

เรียกใช้ `cvd display screenshot --display=` สำหรับอุปกรณ์ Cuttlefish ที่ระบุ

พารามิเตอร์
device ITestDevice: อุปกรณ์ที่จะใช้

displayNumber int: การแสดงผลที่จะถ่ายภาพหน้าจอ

การคืนสินค้า
BufferedImage

ส่ง
DeviceNotAvailableException