# ResValue

# ResValue

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

<br />

```
class ResValue : Serializable
```

<br />

*** ** * ** ***

Resource to be generated by the build system.

## Summary

|                                                                                                                                                   ### Nested types                                                                                                                                                   |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `interface `[ResValue.Key](https://developer.android.com/reference/tools/gradle-api/8.7/com/android/build/api/variant/ResValue.Key)` : `[Serializable](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/Serializable.html) a generated resource is identified by its type+name as you can create |

|                                                                                                                                                             ### Public constructors                                                                                                                                                              |
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [ResValue](https://developer.android.com/reference/tools/gradle-api/8.7/com/android/build/api/variant/ResValue#ResValue(kotlin.String,kotlin.String))`(value: `[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, comment: `[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`?)` |

|                                ### Public properties                                |
|-------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------|
| [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`?` | [comment](https://developer.android.com/reference/tools/gradle-api/8.7/com/android/build/api/variant/ResValue#comment()) Optional comment.  |
| [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)    | [value](https://developer.android.com/reference/tools/gradle-api/8.7/com/android/build/api/variant/ResValue#value()) value for the resource |

## Public constructors

### ResValue

Added in 7.0.0  

```
ResValue(value: String, comment: String? = "Added from the variant API")
```  

## Public properties

### comment

Added in 7.0.0  

```
val comment: String?
```

Optional comment.  

### value

Added in 7.0.0  

```
val value: String
```

value for the resource