com.android.build.gradle.api
[Java] Interface ApkVariant

com.android.build.gradle.api.BaseVariant
  com.android.build.gradle.api.ApkVariant
All Superinterfaces:
BaseVariant

public interface ApkVariant
extends BaseVariant

A Build variant and all its public data.


Method Summary
Dex getDex()

Returns the Dex task.

DefaultTask getInstall()

Returns the installation task.

DefaultProductFlavor getMergedFlavor()

Returns a com.android.builder.DefaultProductFlavor that represents the merging of the default config and the flavors of this build variant.

PackageApplication getPackageApplication()

Returns the APK packaging task.

java.util.List getProductFlavors()

Returns the list of com.android.builder.DefaultProductFlavor for this build variant.

SigningConfig getSigningConfig()

Returns the SigningConfig for this build variant, if one has been specified.

DefaultTask getUninstall()

Returns the uinstallation task.

ZipAlign getZipAlign()

Returns the Zip align task.

boolean isSigningReady()

Returns true if this variant has the information it needs to create a signed APK.

 
Methods inherited from interface BaseVariant
addJavaSourceFoldersToModel, addJavaSourceFoldersToModel, getAidlCompile, getAssemble, getBaseName, getBuildType, getConfig, getDescription, getDirName, getFlavorName, getGenerateBuildConfig, getJavaCompile, getMergeAssets, getMergeResources, getName, getOutputFile, getProcessJavaResources, getProcessManifest, getProcessResources, getRenderscriptCompile, registerJavaGeneratingTask, registerJavaGeneratingTask, setOutputFile
 

Method Detail

getDex

@Nullable
public Dex getDex()
Returns the Dex task.


getInstall

@Nullable
public DefaultTask getInstall()
Returns the installation task. Even for variant for regular project, this can be null if the app cannot be signed.


getMergedFlavor

@NonNull
public DefaultProductFlavor getMergedFlavor()
Returns a com.android.builder.DefaultProductFlavor that represents the merging of the default config and the flavors of this build variant.


getPackageApplication

@Nullable
public PackageApplication getPackageApplication()
Returns the APK packaging task.


getProductFlavors

@NonNull
public java.util.List getProductFlavors()
Returns the list of com.android.builder.DefaultProductFlavor for this build variant. This is always non-null but could be empty.


getSigningConfig

@Nullable
public SigningConfig getSigningConfig()
Returns the SigningConfig for this build variant, if one has been specified.


getUninstall

@Nullable
public DefaultTask getUninstall()
Returns the uinstallation task. For non-library project this is always true even if the APK is not created because signing isn't setup.


getZipAlign

@Nullable
public ZipAlign getZipAlign()
Returns the Zip align task.


isSigningReady

public boolean isSigningReady()
Returns true if this variant has the information it needs to create a signed APK.


 

Copyright (C) 2012 The Android Open Source Project