DeviceConcurrentUtil
public class DeviceConcurrentUtil
extends Object
java.lang.Object | |
↳ | com.android.tradefed.util.DeviceConcurrentUtil |
Berisi metode dan kelas utilitas untuk eksekusi perintah sisi perangkat secara bersamaan
Gunakan ERROR(/ExecutorService)
untuk menjalankan perintah yang diimplementasikan sebagai ShellCommandCallable
, dan gunakan ERROR(/#joinFuture(String,Future,long))
untuk sinkronisasi terhadap ERROR(/Future)
seperti yang dikembalikan oleh ERROR(/ExecutorService)
untuk eksekusi perintah.
Ringkasan
Kelas bertingkat | |
---|---|
class | DeviceConcurrentUtil.ShellCommandCallable <V> |
Metode publik | |
---|---|
static <T> T | joinFuture (String taskDesc, task, long timeout) joinFuture (String taskDesc, task, long timeout) Metode kemudahan untuk bergabung dengan utas saat ini pada |
Metode publik
joinFuture
public static T joinFuture (String taskDesc,task, long timeout)
Metode kemudahan untuk bergabung dengan utas saat ini pada task
DeviceNotAvailableException
dan ERROR(/TimeoutException)
terjadi selama eksekusi diteruskan secara transparan, yang lain dicatat sebagai kesalahan tetapi tidak ditangani.
Parameter | |
---|---|
taskDesc | String : deskripsi tugas untuk tujuan logging |
task | ERROR(/Future) mewakili tugas untuk bergabung |
timeout | long : waktu tunggu untuk tugas |
Kembali | |
---|---|
T | Hasil tugas dengan tipe templat. |
Melempar | |
---|---|
| com.android.tradefed.device.DeviceNotAvailableException |
DeviceNotAvailableException |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2020-09-08 UTC.