IHostOptions

public interface IHostOptions

com.android.tradefed.host.IHostOptions


Host options holder interface. This interface is used to access host-wide options.

Summary

Public methods

abstract Integer getAvailablePermits(IHostOptions.PermitLimitType type)

Returns the number of available permit of a given type

abstract Long getCacheSizeLimit()

Return maximum allowed size(bytes) of the local file cache.

abstract File getClFlashstation()

Returns the remote cl_flashstation script file.

abstract Integer getConcurrentDownloadLimit()

Returns the max number of concurrent downloads allowed.

abstract Integer getConcurrentFlasherLimit()

Returns the max number of concurrent flashing to allow.

abstract Integer getConcurrentVirtualDeviceStartupLimit()

Returns the max number of concurrent virtual device startup allowed.

abstract File getDownloadCacheDir()

Returns the path used for storing downloaded artifacts.

abstract File getFastbootTmpDir()

Returns the path that fastboot should use as temporary folder.

abstract int getInUsePermits(IHostOptions.PermitLimitType type)

Returns the number of permits in use for a given type

abstract getKnownGceDeviceIpPool()

Known gce-device associated with a specific IP.

abstract getKnownPreconfigureVirtualDevicePool()

Known preconfigured virtual device pool.

abstract getKnownRemoteDeviceIpPool()

Known remote-device associated with a specific IP.

abstract getKnownTcpDeviceIpPool()

Known tcp-device associated with a specific IP.

abstract getLabels()

Get labels for the host.

abstract String getNetworkInterface()

Returns the network interface used to connect to remote test devices.

abstract getServiceAccountJsonKeyFiles()

Returns a Map of service account json key files.

abstract long getTestPhaseTimeout()

Returns the Test Phase level timeout specified.

abstract boolean getUseZip64InPartialDownload()

Check if it should use the zip64 format in partial download or not.

abstract void initConcurrentLocks()

Initializes the concurrent locks

abstract boolean isFastbootdEnable()

Returns whether or not fastbootd mode support is enabled.

abstract boolean isFlashstationEnabled()

Returns whether flashing should be done with flashstation.

abstract boolean isHostMetricReportingDisabled()

Returns whether host metric reporting should be disabled.

abstract boolean isIncrementalFlashingEnabled()

Returns whether or not incremental flashing is enabled.

abstract boolean isOptOutOfIncrementalFlashing()

Returns whether the host is opt-out of incremental flashing.

abstract void returnPermit(IHostOptions.PermitLimitType type)

Returns a permit of the given type

abstract boolean shouldFlashWithFuseZip()

Returns whether or not flashing should be done with fuse mounted device image zip file.

abstract Boolean shouldUseSsoClient()

Check if it should use the SingleSignOn client or not.

abstract void takePermit(IHostOptions.PermitLimitType type)

Takes a permit of the given type

abstract void validateOptions()

Validate that the options set on IHostOptions are valid.

Public methods

getAvailablePermits

public abstract Integer getAvailablePermits (IHostOptions.PermitLimitType type)

Returns the number of available permit of a given type

Parameters
type IHostOptions.PermitLimitType

Returns
Integer

getCacheSizeLimit

public abstract Long getCacheSizeLimit ()

Return maximum allowed size(bytes) of the local file cache.

Returns
Long

getClFlashstation

public abstract File getClFlashstation ()

Returns the remote cl_flashstation script file.

Returns
File

getConcurrentDownloadLimit

public abstract Integer getConcurrentDownloadLimit ()

Returns the max number of concurrent downloads allowed. Used by IBuildProvider that downloads remote builds.

Returns
Integer

getConcurrentFlasherLimit

public abstract Integer getConcurrentFlasherLimit ()

Returns the max number of concurrent flashing to allow. Used by DeviceFlashPreparer.

Returns
Integer the concurrent flasher limit.

getConcurrentVirtualDeviceStartupLimit

public abstract Integer getConcurrentVirtualDeviceStartupLimit ()

Returns the max number of concurrent virtual device startup allowed. Used by RemoteAndroidVirtualDevice that startup virtual device.

Returns
Integer

getDownloadCacheDir

public abstract File getDownloadCacheDir ()

Returns the path used for storing downloaded artifacts.

Returns
File

getFastbootTmpDir

public abstract File getFastbootTmpDir ()

Returns the path that fastboot should use as temporary folder.

Returns
File

getInUsePermits

public abstract int getInUsePermits (IHostOptions.PermitLimitType type)

Returns the number of permits in use for a given type

Parameters
type IHostOptions.PermitLimitType

Returns
int

getKnownGceDeviceIpPool

public abstract  getKnownGceDeviceIpPool ()

Known gce-device associated with a specific IP.

Returns

getKnownPreconfigureVirtualDevicePool

public abstract  getKnownPreconfigureVirtualDevicePool ()

Known preconfigured virtual device pool.

Returns

getKnownRemoteDeviceIpPool

public abstract  getKnownRemoteDeviceIpPool ()

Known remote-device associated with a specific IP.

Returns

getKnownTcpDeviceIpPool

public abstract  getKnownTcpDeviceIpPool ()

Known tcp-device associated with a specific IP.

Returns

getLabels

public abstract  getLabels ()

Get labels for the host.

Returns

getNetworkInterface

public abstract String getNetworkInterface ()

Returns the network interface used to connect to remote test devices.

Returns
String

getServiceAccountJsonKeyFiles

public abstract  getServiceAccountJsonKeyFiles ()

Returns a Map of service account json key files.

Returns

getTestPhaseTimeout

public abstract long getTestPhaseTimeout ()

Returns the Test Phase level timeout specified. Default will be 0 for no timeouts.

Returns
long

getUseZip64InPartialDownload

public abstract boolean getUseZip64InPartialDownload ()

Check if it should use the zip64 format in partial download or not.

Returns
boolean

initConcurrentLocks

public abstract void initConcurrentLocks ()

Initializes the concurrent locks

isFastbootdEnable

public abstract boolean isFastbootdEnable ()

Returns whether or not fastbootd mode support is enabled.

Returns
boolean

isFlashstationEnabled

public abstract boolean isFlashstationEnabled ()

Returns whether flashing should be done with flashstation.

Returns
boolean

isHostMetricReportingDisabled

public abstract boolean isHostMetricReportingDisabled ()

Returns whether host metric reporting should be disabled.

Returns
boolean

isIncrementalFlashingEnabled

public abstract boolean isIncrementalFlashingEnabled ()

Returns whether or not incremental flashing is enabled.

Returns
boolean

isOptOutOfIncrementalFlashing

public abstract boolean isOptOutOfIncrementalFlashing ()

Returns whether the host is opt-out of incremental flashing.

Returns
boolean

returnPermit

public abstract void returnPermit (IHostOptions.PermitLimitType type)

Returns a permit of the given type

Parameters
type IHostOptions.PermitLimitType

shouldFlashWithFuseZip

public abstract boolean shouldFlashWithFuseZip ()

Returns whether or not flashing should be done with fuse mounted device image zip file.

Returns
boolean

shouldUseSsoClient

public abstract Boolean shouldUseSsoClient ()

Check if it should use the SingleSignOn client or not.

Returns
Boolean

takePermit

public abstract void takePermit (IHostOptions.PermitLimitType type)

Takes a permit of the given type

Parameters
type IHostOptions.PermitLimitType

validateOptions

public abstract void validateOptions ()

Validate that the options set on IHostOptions are valid.

Throws
ConfigurationException