PushFilePreparer
public
class
PushFilePreparer
extends BaseTargetPreparer
implements
IAbiReceiver,
IDiscoverDependencies,
IInvocationContextReceiver
| java.lang.Object | ||
| ↳ | com.android.tradefed.targetprep.BaseTargetPreparer | |
| ↳ | com.android.tradefed.targetprep.PushFilePreparer | |
ITargetPreparer 會嘗試將任意數量的檔案從任何主機路徑推送至任何裝置路徑。
應在刷新新版本後,以及執行 DeviceSetup (如果已啟用) 後執行
摘要
公用建構函式 | |
|---|---|
PushFilePreparer()
|
|
公用方法 | |
|---|---|
IAbi
|
getAbi()
|
final
|
getPushSpecs(ITestDevice device)
建立要推送的檔案清單。 |
boolean
|
isCleanUpEnabled()
|
|
reportDependencies()
|
File
|
resolveRelativeFilePath(IBuildInfo buildInfo, String fileName)
透過 |
void
|
setAbi(IAbi abi)
|
void
|
setInvocationContext(IInvocationContext invocationContext)
|
void
|
setUp(TestInformation testInfo)
|
boolean
|
shouldAbortOnFailure()
是否要在推送失敗時中止。 |
boolean
|
shouldRemountSystem()
|
boolean
|
shouldRemountVendor()
|
void
|
tearDown(TestInformation testInfo, Throwable e)
|
公用建構函式
PushFilePreparer
public PushFilePreparer ()
公用方法
getPushSpecs
public finalgetPushSpecs (ITestDevice device)
建立要推送的檔案清單。
| 參數 | |
|---|---|
device |
ITestDevice |
| 傳回 | |
|---|---|
|
|
| 擲回 | |
|---|---|
TargetSetupError |
|
isCleanUpEnabled
public boolean isCleanUpEnabled ()
| 傳回 | |
|---|---|
boolean |
|
reportDependencies
publicreportDependencies ()
| 傳回 | |
|---|---|
|
|
resolveRelativeFilePath
public File resolveRelativeFilePath (IBuildInfo buildInfo, String fileName)
透過 IBuildInfo 和測試案例目錄解析相對檔案路徑。
| 參數 | |
|---|---|
buildInfo |
IBuildInfo:建構成果資訊 |
fileName |
String:要解析的相對檔案路徑 |
| 傳回 | |
|---|---|
File |
建構資訊或測試案例目錄中的檔案 |
setInvocationContext
public void setInvocationContext (IInvocationContext invocationContext)
| 參數 | |
|---|---|
invocationContext |
IInvocationContext |
setUp
public void setUp (TestInformation testInfo)
| 參數 | |
|---|---|
testInfo |
TestInformation |
| 擲回 | |
|---|---|
BuildError |
|
DeviceNotAvailableException |
|
TargetSetupError |
|
shouldAbortOnFailure
public boolean shouldAbortOnFailure ()
是否要在推送失敗時中止。
| 傳回 | |
|---|---|
boolean |
|
shouldRemountSystem
public boolean shouldRemountSystem ()
| 傳回 | |
|---|---|
boolean |
|
shouldRemountVendor
public boolean shouldRemountVendor ()
| 傳回 | |
|---|---|
boolean |
|
tearDown
public void tearDown (TestInformation testInfo, Throwable e)
| 參數 | |
|---|---|
testInfo |
TestInformation |
e |
Throwable |
| 擲回 | |
|---|---|
DeviceNotAvailableException |
|