PushFilePreparer

public class PushFilePreparer
extends BaseTargetPreparer implements IAbiReceiver, IDiscoverDependencies, IInvocationContextReceiver

java.lang.Object
   ↳ com.android.tradefed.targetprep.BaseTargetPreparer
     ↳ com.android.tradefed.targetprep.PushFilePreparer


Một ITargetPreparer cố gắng chuyển bất kỳ số lượng tệp nào từ bất kỳ đường dẫn máy chủ lưu trữ nào đến bất kỳ đường dẫn thiết bị nào.

Phải được thực hiện *sau khi* một bản dựng mới được flash và *sau khi* DeviceSetup chạy (nếu được bật)

Tóm tắt

Hàm khởi tạo công khai

PushFilePreparer()

Phương thức công khai

IAbi getAbi()

final Map<String, File> getPushSpecs(ITestDevice device)

Tạo danh sách các tệp cần đẩy.

boolean isCleanUpEnabled()
Set<String> reportDependencies()
File resolveRelativeFilePath(IBuildInfo buildInfo, String fileName)

Giải quyết đường dẫn tệp tương đối thông qua IBuildInfo và các thư mục trường hợp kiểm thử.

void setAbi(IAbi abi)

void setInvocationContext(IInvocationContext invocationContext)

void setUp(TestInformation testInfo)

boolean shouldAbortOnFailure()

Có huỷ khi thao tác đẩy không thành công hay không.

boolean shouldRemountSystem()
boolean shouldRemountVendor()
void tearDown(TestInformation testInfo, Throwable e)

Hàm khởi tạo công khai

PushFilePreparer

public PushFilePreparer ()

Phương thức công khai

getAbi

public IAbi getAbi ()

Giá trị trả về
IAbi

getPushSpecs

public final Map<String, File> getPushSpecs (ITestDevice device)

Tạo danh sách các tệp cần đẩy.

Tham số
device ITestDevice

Giá trị trả về
Map<String, File>

Gửi
TargetSetupError

isCleanUpEnabled

public boolean isCleanUpEnabled ()

Giá trị trả về
boolean

reportDependencies

public Set<String> reportDependencies ()

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

resolveRelativeFilePath

public File resolveRelativeFilePath (IBuildInfo buildInfo, 
                String fileName)

Giải quyết đường dẫn tệp tương đối thông qua IBuildInfo và các thư mục trường hợp kiểm thử.

Tham số
buildInfo IBuildInfo: thông tin về cấu phần phần mềm bản dựng

fileName String: đường dẫn tệp tương đối cần phân giải

Giá trị trả về
File tệp từ thư mục thông tin bản dựng hoặc thư mục trường hợp kiểm thử

setAbi

public void setAbi (IAbi abi)

Tham số
abi IAbi

setInvocationContext

public void setInvocationContext (IInvocationContext invocationContext)

Tham số
invocationContext IInvocationContext

setUp

public void setUp (TestInformation testInfo)

Tham số
testInfo TestInformation

Gửi
BuildError
DeviceNotAvailableException
TargetSetupError

shouldAbortOnFailure

public boolean shouldAbortOnFailure ()

Có huỷ khi thao tác đẩy không thành công hay không.

Giá trị trả về
boolean

shouldRemountSystem

public boolean shouldRemountSystem ()

Giá trị trả về
boolean

shouldRemountVendor

public boolean shouldRemountVendor ()

Giá trị trả về
boolean

tearDown

public void tearDown (TestInformation testInfo, 
                Throwable e)

Tham số
testInfo TestInformation

e Throwable

Gửi
DeviceNotAvailableException