use of com.android.tools.idea.sdk.install.patch.PatchInstallerFactory in project android by JetBrains.
the class StudioSdkInstallerUtil method createInstallerFactory.
/**
* Find the best {@link InstallerFactory} for the given {@link RepoPackage}.
*/
@NotNull
public static InstallerFactory createInstallerFactory(@NotNull AndroidSdkHandler sdkHandler) {
InstallerFactory factory;
InstallerFactory basicFactory = new BasicInstallerFactory();
if (Boolean.getBoolean("sdk.patches.disable")) {
factory = basicFactory;
} else {
factory = new PatchInstallerFactory();
factory.setFallbackFactory(basicFactory);
}
factory.setListenerFactory(new StudioSdkInstallListenerFactory(sdkHandler));
return factory;
}
Aggregations