# ApplicationVariantBuilder

# ApplicationVariantBuilder

```
interface ApplicationVariantBuilder : VariantBuilder, HasAndroidTestBuilder, HasTestFixturesBuilder
```

|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [com.android.build.api.variant.ApplicationVariantBuilder](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ApplicationVariantBuilder#) |

Application specific variant object that contains properties that will determine the variant's build flow.

For example, an application variant may have minification on or off, or have a different minSdkVersion from the other variants.

All these properties must be resolved during configuration time as[org.gradle.api.Task](https://docs.gradle.org/current/javadoc/org/gradle/api/Task.html)representing the variant build flows must be created.

## Summary

| ### Inherited functions ||
|---|---|
| From class[VariantBuilder](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder) |------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [Unit](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) | [registerExtension](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#registerExtension(java.lang.Class,%20com.android.build.api.variant.VariantBuilder.registerExtension.T))`(`type:` `[Class](http://docs.oracle.com/javase/8/docs/api/java/lang/Class.html)<out` `T>`, `instance:` `T`)` <br /> Registers an extension object to the variant object. Extension objects can be looked up during the[AndroidComponentsExtension.onVariants](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/AndroidComponentsExtension#onVariants(com.android.build.api.variant.VariantSelector,%20kotlin.Function1))callbacks by using the[Variant.getExtension](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/Variant#getExtension(java.lang.Class))API. This is very useful for third party plugins that want to attach some variant specific configuration object to the Android Gradle Plugin variant object and make it available to other plugins. <br /> | ||

|                                                                                                                                                                                                                  ### Properties                                                                                                                                                                                                                   ||
|-------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| abstract[Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)                                                            | [debuggable](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ApplicationVariantBuilder#debuggable:kotlin.Boolean) <br />                                                                                                                        |
| abstract[DependenciesInfoBuilder](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/DependenciesInfoBuilder) | [dependenciesInfo](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ApplicationVariantBuilder#dependenciesInfo:com.android.build.api.variant.DependenciesInfoBuilder) Specify whether to include SDK dependency information in APKs and Bundles. |

| ### Inherited properties ||
|---|---|
| From class[HasAndroidTestBuilder](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/HasAndroidTestBuilder) |------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) | [androidTestEnabled](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/HasAndroidTestBuilder#androidTestEnabled:kotlin.Boolean) <br /> Set to`true`if the variant's has any android tests, false otherwise. Value is[Boolean#True](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ApplicationVariantBuilder#)by default. <br /> | | [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) | [enableAndroidTest](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/HasAndroidTestBuilder#enableAndroidTest:kotlin.Boolean) <br /> Set to`true`if the variant's has any android tests, false otherwise. Value is[Boolean#True](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ApplicationVariantBuilder#)by default. <br />   | ||
| From class[ComponentIdentity](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ComponentIdentity) |----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?                                                                                                                                                                                                                                                            | [buildType](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ComponentIdentity#buildType:kotlin.String) <br /> Build type name, might be replaced with access to locked DSL object once ready. <br />                                                                                                                                                                                                                                    | | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?                                                                                                                                                                                                                                                            | [flavorName](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ComponentIdentity#flavorName:kotlin.String) <br /> The multi-flavor name of the variant. This does not include the build type. If no flavors are present, this will return null The full name of the variant is queried via[name](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ComponentIdentity#name:kotlin.String). <br /> | | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)                                                                                                                                                                                                                                                             | [name](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ComponentIdentity#name:kotlin.String) <br /> Component's name. <br />                                                                                                                                                                                                                                                                                                            | | [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html)<[Pair](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-pair/index.html)<[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html),` `[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)>> | [productFlavors](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ComponentIdentity#productFlavors:kotlin.collections.List) <br /> List of flavor names, might be replaced with access to locked DSL objects once ready. The order is properly sorted based on the associated dimension order. <br />                                                                                                                                    | ||
| From class[ComponentBuilder](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ComponentBuilder) |------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) | [enable](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ComponentBuilder#enable:kotlin.Boolean) <br /> Set to`true`if the variant is active and should be configured, false otherwise. <br /> | | [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) | [enabled](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ComponentBuilder#enabled:kotlin.Boolean) <br />                                                                                      | ||
| From class[HasTestFixturesBuilder](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/HasTestFixturesBuilder) |------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) | [enableTestFixtures](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/HasTestFixturesBuilder#enableTestFixtures:kotlin.Boolean) <br /> Set to`true`if the variant's has test fixtures,`false`otherwise. Default value will match[com.android.build.api.dsl.TestFixtures.enable](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/dsl/TestFixtures.html#enable:kotlin.Boolean)value that is set through the extension via[com.android.build.api.dsl.TestedExtension.testFixtures](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/dsl/TestedExtension.html#testFixtures(kotlin.Function1)). <br /> | ||
| From class[VariantBuilder](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder) |------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) | [enableUnitTest](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#enableUnitTest:kotlin.Boolean) <br /> Set to`true`if the variant's has any unit tests, false otherwise. Value is[Boolean#True](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ApplicationVariantBuilder#)by default. <br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           | | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)?        | [maxSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#maxSdk:kotlin.Int) <br /> Gets the maximum supported SDK Version for this variant. <br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 | | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)?        | [minSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdk:kotlin.Int) <br /> Gets or sets the minimum supported SDK Version for this variant. Setting this it will override previous calls of[minSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdk:kotlin.Int)and[minSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdkPreview:kotlin.String)setters. Only one of[minSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdk:kotlin.Int)and[minSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdkPreview:kotlin.String)should be set. <br />                                                           | | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?  | [minSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdkPreview:kotlin.String) <br /> Gets or sets the minimum supported SDK Version for this variant as a Preview codename. Setting this it will override previous calls of[minSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdk:kotlin.Int)and[minSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdkPreview:kotlin.String)setters. Only one of[minSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdk:kotlin.Int)and[minSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#minSdkPreview:kotlin.String)should be set. <br />                    | | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)         | [renderscriptTargetApi](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#renderscriptTargetApi:kotlin.Int) <br /> Specifies the bytecode version to be generated. We recommend you set this value to the lowest API level able to provide all the functionality you are using <br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                | | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)?        | [targetSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdk:kotlin.Int) <br /> Gets or sets the target SDK Version for this variant as a Preview codename. Setting this it will override previous calls of[targetSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdk:kotlin.Int)and[targetSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdkPreview:kotlin.String)setters. Only one of[targetSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdk:kotlin.Int)and[targetSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdkPreview:kotlin.String)should be set. <br />                  | | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)?  | [targetSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdkPreview:kotlin.String) <br /> Gets or sets the target SDK Version for this variant as a Preview codename. Setting this it will override previous calls of[targetSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdk:kotlin.Int)and[targetSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdkPreview:kotlin.String)setters. Only one of[targetSdk](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdk:kotlin.Int)and[targetSdkPreview](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#targetSdkPreview:kotlin.String)should be set. <br /> | | [Boolean](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html) | [unitTestEnabled](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/VariantBuilder#unitTestEnabled:kotlin.Boolean) <br /> Set to`true`if the variant's has any unit tests, false otherwise. Value is[Boolean#True](https://developer.android.com/reference/tools/gradle-api/7.1/com/android/build/api/variant/ApplicationVariantBuilder#)by default. <br />                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         | ||

## Properties

### debuggable

```
abstract val debuggable: Boolean
```  

### dependenciesInfo

```
abstract val dependenciesInfo: DependenciesInfoBuilder
```

Specify whether to include SDK dependency information in APKs and Bundles.