IncrementalImageUtil

public class IncrementalImageUtil
extends Object

java.lang.Object
   ↳ com.android.tradefed.util.image.IncrementalImageUtil


A utility to leverage the incremental image and device update.

Summary

Fields

public static final DYNAMIC_PARTITIONS_TO_DIFF

Public constructors

IncrementalImageUtil(ITestDevice device, File deviceImage, File bootloader, File baseband, File targetImage, File createSnapshot)

Public methods

static IncrementalImageUtil initialize(ITestDevice device, IDeviceBuildInfo build, File createSnapshot, boolean isIsolatedSetup)
static boolean isSnapshotInUse(ITestDevice device)

Returns whether device is currently using snapshots or not.

static boolean isSnapshotSupported(ITestDevice device)

Returns whether or not we can use the snapshot logic to update the device

void notifyBasebadNeedsRevert()
void notifyBootloaderNeedsRevert()
void teardownDevice()
void updateDevice()

Updates the device using the snapshot logic.

Fields

DYNAMIC_PARTITIONS_TO_DIFF

public static final  DYNAMIC_PARTITIONS_TO_DIFF

Public constructors

IncrementalImageUtil

public IncrementalImageUtil (ITestDevice device, 
                File deviceImage, 
                File bootloader, 
                File baseband, 
                File targetImage, 
                File createSnapshot)

Parameters
device ITestDevice

deviceImage File

bootloader File

baseband File

targetImage File

createSnapshot File

Public methods

initialize

public static IncrementalImageUtil initialize (ITestDevice device, 
                IDeviceBuildInfo build, 
                File createSnapshot, 
                boolean isIsolatedSetup)

Parameters
device ITestDevice

build IDeviceBuildInfo

createSnapshot File

isIsolatedSetup boolean

Returns
IncrementalImageUtil

Throws
DeviceNotAvailableException

isSnapshotInUse

public static boolean isSnapshotInUse (ITestDevice device)

Returns whether device is currently using snapshots or not.

Parameters
device ITestDevice

Returns
boolean

Throws
DeviceNotAvailableException

isSnapshotSupported

public static boolean isSnapshotSupported (ITestDevice device)

Returns whether or not we can use the snapshot logic to update the device

Parameters
device ITestDevice

Returns
boolean

Throws
DeviceNotAvailableException

notifyBasebadNeedsRevert

public void notifyBasebadNeedsRevert ()

notifyBootloaderNeedsRevert

public void notifyBootloaderNeedsRevert ()

teardownDevice

public void teardownDevice ()

Throws
DeviceNotAvailableException

updateDevice

public void updateDevice ()

Updates the device using the snapshot logic.

Throws
DeviceNotAvailableException
TargetSetupError