等待設備日期時間準備器
public class WaitForDeviceDatetimePreparer
extends BaseTargetPreparer
java.lang.Object | ||
↳ | com.android.tradefed.targetprep.BaseTargetPreparer | |
↳ | com.android.tradefed.targetprep.WaitForDeviceDatetimePreparer |
等待在設備上設定日期時間的ITargetPreparer
(可選)如果未在逾時內設定日期時間,則此準備器可以強制TargetSetupError
,或將主機日期時間強製到裝置上,
概括
公共構造函數 | |
---|---|
WaitForDeviceDatetimePreparer () |
公共方法 | |
---|---|
void | setDatetimeWaitTimeout (long datetimeWaitTimeout) 設定等待有效設備日期時間的逾時 |
void | setForceDatetime (boolean forceDatetime) 設定日期時間是否應從主機強製到設備 |
void | setForceSetupError (boolean forceSetupError) 如果日期時間設定不正確,則設定用於強制 |
void | setUp ( TestInformation testInfo) |
受保護的方法 | |
---|---|
IRunUtil | getRunUtil () |
公共構造函數
等待設備日期時間準備器
public WaitForDeviceDatetimePreparer ()
公共方法
設定日期時間等待超時
public void setDatetimeWaitTimeout (long datetimeWaitTimeout)
設定等待有效設備日期時間的逾時
參數 | |
---|---|
datetimeWaitTimeout | long |
設定強制日期時間
public void setForceDatetime (boolean forceDatetime)
設定日期時間是否應從主機強製到設備
參數 | |
---|---|
forceDatetime | boolean |
setForce設定錯誤
public void setForceSetupError (boolean forceSetupError)
如果日期時間設定不正確,則設定用於強制TargetSetupError
布林值。
參數 | |
---|---|
forceSetupError | boolean |
設定
public void setUp (TestInformation testInfo)
參數 | |
---|---|
testInfo | TestInformation |
投擲 | |
---|---|
BuildError | |
DeviceNotAvailableException | |
TargetSetupError |