# Rating.Builder

# Rating.Builder

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/com/google/android/engage/common/datamodel/Rating.Builder "View this page in Java")  

<br />

```
class Rating.Builder
```

<br />

*** ** * ** ***

Builder class for[Rating](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating).

## Summary

|                                                      ### Public constructors                                                      |
|-----------------------------------------------------------------------------------------------------------------------------------|
| [Builder](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder#Builder())`()` |

|                                                     ### Public functions                                                      |
|-------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Rating](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating)`!`                 | [build](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder#build())`()`                                                                                                                                                                                                                                                                                            |
| [Rating.Builder](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder)`!` | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setCount](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder#setCount(java.lang.String))`(count: `[String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`!)` Sets the count of the rating. e.g. 1.2k, 12k etc |
| [Rating.Builder](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder)`!` | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setCountValue](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder#setCountValue(long))`(countValue: `[Long](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-long/index.html)`)` Sets the count of the rating.                      |
| [Rating.Builder](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder)`!` | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setCurrentValue](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder#setCurrentValue(double))`(currentValue: `[Double](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-double/index.html)`)` Sets the current value of the rating.  |
| [Rating.Builder](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder)`!` | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setMaxValue](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Rating.Builder#setMaxValue(double))`(maxValue: `[Double](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-double/index.html)`)` Sets the max value of the rating.                  |

## Public constructors

### Builder

```
Builder()
```  

## Public functions

### build

```
fun build(): Rating!
```  

### setCount

```
@CanIgnoreReturnValue
fun setCount(count: String!): Rating.Builder!
```

Sets the count of the rating. e.g. 1.2k, 12k etc

Optional.  

### setCountValue

```
@CanIgnoreReturnValue
fun setCountValue(countValue: Long): Rating.Builder!
```

Sets the count of the rating.

Optional.  

### setCurrentValue

```
@CanIgnoreReturnValue
fun setCurrentValue(currentValue: Double): Rating.Builder!
```

Sets the current value of the rating.

Required.  

### setMaxValue

```
@CanIgnoreReturnValue
fun setMaxValue(maxValue: Double): Rating.Builder!
```

Sets the max value of the rating.

Required.