use of com.android.tools.build.bundletool.model.BundleModule.ModuleType in project bundletool by google.
the class ModuleCompressionManager method shouldForceUncompressAssets.
/**
* Returns whether all assets should be uncompressed in that module.
*/
boolean shouldForceUncompressAssets(BundleConfig bundleConfig, AndroidManifest moduleManifest) {
boolean shouldForceInstallTimeAssetModulesUncompressed = !bundleConfig.getCompression().getInstallTimeAssetModuleDefaultCompression().equals(AssetModuleCompression.COMPRESSED);
ModuleDeliveryType moduleDeliveryType = moduleManifest.getModuleDeliveryType();
ModuleType moduleType = moduleManifest.getModuleType();
boolean isInstallTimeModule = moduleDeliveryType.equals(ALWAYS_INITIAL_INSTALL) || moduleDeliveryType.equals(CONDITIONAL_INITIAL_INSTALL);
return moduleType.equals(ModuleType.ASSET_MODULE) && (shouldForceInstallTimeAssetModulesUncompressed || !isInstallTimeModule);
}
Aggregations