自 2025 年 3 月 27 日起,我们建议您使用 android-latest-release 而非 aosp-main 构建 AOSP 并为其做出贡献。如需了解详情,请参阅 AOSP 的变更。
  
         
       
     
  
  
  
    
  
  
  
    
    
      
    
    
      
      使用集合让一切井井有条
    
    
      
      根据您的偏好保存内容并对其进行分类。
    
  
  
    
  
  
  
  
    
  
  
    
    
    
  
  
HostOptions
  public
  
  
  
  class
  HostOptions
  
    extends Object
  
  
  
  
  
      implements
      
        IHostOptions
      
  
  
  
    
    | java.lang.Object | 
  
  
    
      | ↳ | com.android.tradefed.host.HostOptions | 
  
  
    
  主机选项持有者类。
 此类用于存储主机级选项。
摘要
公共构造函数
    HostOptions
    
public HostOptions ()
    
    
    
  
 
公共方法
    getAvailablePermits
    
public Integer getAvailablePermits (IHostOptions.PermitLimitType type)
    
    
    
  返回指定类型的可用许可数量
    
    | 参数 | 
|---|
      
        | type | IHostOptions.PermitLimitType | 
    
    
 
    getCacheSizeLimit
    
public Long getCacheSizeLimit ()
    
    
    
  返回本地文件缓存的允许大小上限(字节)。
    
 
    getConcurrentDownloadLimit
    
public Integer getConcurrentDownloadLimit ()
    
    
    
  返回允许的并发下载数量上限。供下载远程 build 的 IBuildProvider 使用。
    
 
    getConcurrentFlasherLimit
    
public Integer getConcurrentFlasherLimit ()
    
    
    
  返回允许的并发刷写次数上限。由 DeviceFlashPreparer 使用。
    
 
    getConcurrentVirtualDeviceStartupLimit
    
public Integer getConcurrentVirtualDeviceStartupLimit ()
    
    
    
  返回允许的并发虚拟设备启动的最大数量。供启动虚拟设备的 RemoteAndroidVirtualDevice 使用。
    
 
    getDownloadCacheDir
    
public File getDownloadCacheDir ()
    
    
    
  返回用于存储下载的工件的路径。
    
 
    getFastbootTmpDir
    
public File getFastbootTmpDir ()
    
    
    
  返回 fastboot 应用作临时文件夹的路径。
    
 
    getKnownGceDeviceIpPool
    
public  getKnownGceDeviceIpPool ()
    
    
    
  与特定 IP 地址关联的已知 gce-device。
    
 
    
    
public  getKnownPreconfigureNativeDevicePool ()
    
    
    
  已知的预配置原生设备 IP 池。
    
 
    
    
public  getKnownPreconfigureVirtualDevicePool ()
    
    
    
  已知的预配置虚拟设备池。
    
 
    getKnownRemoteDeviceIpPool
    
public  getKnownRemoteDeviceIpPool ()
    
    
    
  与特定 IP 地址关联的已知远程设备。
    
 
    getLabels
    
public  getLabels ()
    
    
    
  获取主机的标签。
    
 
    getNetworkInterface
    
public String getNetworkInterface ()
    
    
    
  返回用于连接到远程测试设备的网络接口。
    
 
    getServiceAccountJsonKeyFiles
    
public  getServiceAccountJsonKeyFiles ()
    
    
    
  返回服务账号 JSON 密钥文件的 Map。
    
 
    getTestPhaseTimeout
    
public long getTestPhaseTimeout ()
    
    
    
  返回指定的测试阶段级超时。默认值为 0(无超时)。
    
 
    getUseZip64InPartialDownload
    
public boolean getUseZip64InPartialDownload ()
    
    
    
  检查它是否应在部分下载时使用 zip64 格式。
    
 
    initConcurrentLocks
    
public void initConcurrentLocks ()
    
    
    
  初始化并发锁
 
    isFastbootdEnable
    
public boolean isFastbootdEnable ()
    
    
    
  返回是否启用 fastbootd 模式支持。
    
 
    isHostMetricReportingDisabled
    
public boolean isHostMetricReportingDisabled ()
    
    
    
  返回是否应停用主机指标报告。
    
 
    isIncrementalFlashingEnabled
    
public boolean isIncrementalFlashingEnabled ()
    
    
    
  返回是否启用了增量刷写。
    
 
    isOptOutOfIncrementalFlashing
    
public boolean isOptOutOfIncrementalFlashing ()
    
    
    
  返回主机是否选择停用增量刷写。
    
 
    shouldFlashWithFuseZip
    
public boolean shouldFlashWithFuseZip ()
    
    
    
  返回是否应使用已装载保险丝的设备映像 ZIP 文件进行刷写。
    
 
    shouldUseSsoClient
    
public Boolean shouldUseSsoClient ()
    
    
    
  检查它是否应使用 SingleSignOn 客户端。
    
 
    validateOptions
    
public void validateOptions ()
    
    
    
  验证在 IHostOptions 上设置的选项是否有效。
      
  
 
 
 
  
  
  
 
  
    
    
      
    
    
  
       
    
    
  
  
  本页面上的内容和代码示例受内容许可部分所述许可的限制。Java 和 OpenJDK 是 Oracle 和/或其关联公司的注册商标。
  最后更新时间 (UTC):2025-07-27。
  
  
  
    
      [[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["没有我需要的信息","missingTheInformationINeed","thumb-down"],["太复杂/步骤太多","tooComplicatedTooManySteps","thumb-down"],["内容需要更新","outOfDate","thumb-down"],["翻译问题","translationIssue","thumb-down"],["示例/代码问题","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-07-27。"],[],[]]