com.android.builder.model
Interface AndroidArtifact

All Superinterfaces:
BaseArtifact

public interface AndroidArtifact
extends BaseArtifact

The information for a generated Android artifact.


Method Summary
 java.lang.String getApplicationId()
          Returns the application id of this artifact.
 java.io.File getGeneratedManifest()
          The generated manifest for this variant's artifact.
 java.util.Collection<java.io.File> getGeneratedResourceFolders()
          Returns all the resource folders that are generated.
 java.util.Collection<java.io.File> getGeneratedSourceFolders()
          Returns all the source folders that are generated.
 java.io.File getOutputFile()
          Returns the output file for this artifact.
 java.lang.String getSigningConfigName()
          Returns the name of the SigningConfig used for the signing.
 java.lang.String getSourceGenTaskName()
          Returns the name of the task used to generate the source code.
 boolean isSigned()
          Returns whether the output file is signed.
 
Methods inherited from interface com.android.builder.model.BaseArtifact
getAssembleTaskName, getClassesFolder, getDependencies, getJavaCompileTaskName, getMultiFlavorSourceProvider, getName, getVariantSourceProvider
 

Method Detail

getOutputFile

@NonNull
java.io.File getOutputFile()
Returns the output file for this artifact. Depending on whether the project is an app or a library project, this could be an apk or an aar file. For test artifact for a library project, this would also be an apk.

Returns:
the output file.

isSigned

boolean isSigned()
Returns whether the output file is signed. This is always false for the main artifact of a library project.

Returns:
true if the app is signed.

getSigningConfigName

@Nullable
java.lang.String getSigningConfigName()
Returns the name of the SigningConfig used for the signing. If none are setup or if this is the main artifact of a library project, then this is null.

Returns:
the name of the setup signing config.

getApplicationId

@NonNull
java.lang.String getApplicationId()
Returns the application id of this artifact.

Returns:
the application id.

getSourceGenTaskName

@NonNull
java.lang.String getSourceGenTaskName()
Returns the name of the task used to generate the source code. The actual value might depend on the build system front end.

Returns:
the name of the code generating task.

getGeneratedManifest

@NonNull
java.io.File getGeneratedManifest()
The generated manifest for this variant's artifact.


getGeneratedSourceFolders

@NonNull
java.util.Collection<java.io.File> getGeneratedSourceFolders()
Returns all the source folders that are generated. This is typically folders for the R, the aidl classes, and the renderscript classes.

Returns:
a list of folders.

getGeneratedResourceFolders

@NonNull
java.util.Collection<java.io.File> getGeneratedResourceFolders()
Returns all the resource folders that are generated. This is typically the renderscript output and the merged resources.

Returns:
a list of folder.