AndroidVariant

interface AndroidVariant

A facade of some of the interactions with Android module variants.

Properties

Link copied to clipboard
abstract val buildType: String?

The name of the variant's build type, if present.

Link copied to clipboard

The packaging options for handling resource merge conflicts from dependencies.

Link copied to clipboard
abstract val variantName: String

The name of the variant.

Functions

Link copied to clipboard
open fun name(prefix: String = "", suffix: String = ""): String

Returns a string using an optional prefix and suffix to surround the variant name, applying the default snake-casing formatting convention that Gradle naming often follows.

Link copied to clipboard
abstract fun <T : Task> registerAarTransform(task: TaskProvider<T>, inputAar: (T) -> RegularFileProperty, outputAar: (T) -> RegularFileProperty)

Register a transformation of the AAR produced by this variant. inputAar is set to the input, and the transformed AAR should be written to outputAar.