# ProductFlavorAttr

[View Source](https://cs.android.com/search?q=file:com/android/build/api/attributes/ProductFlavorAttr.kt+class:com.android.build.api.attributes.ProductFlavorAttr)  
Added in 4.2.0  


```
interface ProductFlavorAttr : Named
```

<br />

*** ** * ** ***

Type for the attribute holding ProductFlavor information.

There can be more than one attribute associated to each [org.gradle.api.artifacts.Configuration](https://docs.gradle.org/current/javadoc/org/gradle/api/artifacts/Configuration.html) object, where each represents a different flavor dimension.

The key should be created with `ProductFlavorAttr.of(flavorDimension)`.

## Summary

| ### Public companion functions |
|---|---|
| [Attribute](https://docs.gradle.org/current/javadoc/org/gradle/api/attributes/Attribute.html)`<`[ProductFlavorAttr](https://developer.android.com/reference/tools/gradle-api/9.1/com/android/build/api/attributes/ProductFlavorAttr)`>` | [of](https://developer.android.com/reference/tools/gradle-api/9.1/com/android/build/api/attributes/ProductFlavorAttr.Companion#of(kotlin.String))`(flavorDimension: `[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`)` Returns a product flavor attribute for the given flavor dimension |

| ### Inherited functions |
|---|
| From [org.gradle.api.Named](https://docs.gradle.org/current/javadoc/org/gradle/api/Named.html) |---|---| | [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [getName](https://docs.gradle.org/current/javadoc/org/gradle/api/Named.html#getName--)`()` | |

## Public companion functions

### of

Added in 7.1.0  

```
fun of(flavorDimension: String): Attribute<ProductFlavorAttr>
```

Returns a product flavor attribute for the given flavor dimension  

| Parameters |
|---|---|
| `flavorDimension: `[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | The name of the flavor dimension, as specified in the Android Gradle Plugin DSL. |