# MusicVideoEntity.Builder

# MusicVideoEntity.Builder

*** ** * ** ***

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

<br />

```
public final class MusicVideoEntity.Builder
```

<br />

*** ** * ** ***

Builder class for[MusicVideoEntity](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity).

## Summary

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

|                                                           ### Public methods                                                           |
|----------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [addArtist](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#addArtist(java.lang.String))`(`[String](https://developer.android.com/reference/java/lang/String.html)` artist)` Adds artist of the music video.                                                                                                                                                               |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [addArtists](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#addArtists(java.util.List<java.lang.String>))`(`[List](https://developer.android.com/reference/java/util/List.html)`<`[String](https://developer.android.com/reference/java/lang/String.html)`> artists)` Adds the list of artists of the music video.                                                        |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [addContentRating](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#addContentRating(java.lang.String))`(`[String](https://developer.android.com/reference/java/lang/String.html)` contentRating)` Adds the content rating of the music video.                                                                                                                              |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [addContentRatings](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#addContentRatings(java.util.List<java.lang.String>))`(`[List](https://developer.android.com/reference/java/util/List.html)`<`[String](https://developer.android.com/reference/java/lang/String.html)`> contentRatings)` Adds the list of content ratings of the music video.                           |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [addPosterImage](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#addPosterImage(com.google.android.engage.common.datamodel.Image))`(`[Image](https://developer.android.com/reference/com/google/android/engage/common/datamodel/Image)` image)` Add a poster image of the entity.                                                                                          |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [addPosterImages](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#addPosterImages(java.util.List<com.google.android.engage.common.datamodel.Image>))`(`[List](https://developer.android.com/reference/java/util/List.html)`<`[Image](https://developer.android.com/reference/com/google/android/engage/common/datamodel/Image)`> images)` Add poster images of the entity. |
| [MusicVideoEntity](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity)                 | [build](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#build())`()`                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setDescription](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setDescription(java.lang.String))`(`[String](https://developer.android.com/reference/java/lang/String.html)` description)` Adds the description of the audio entity.                                                                                                                                      |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setDownloadedOnDevice](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setDownloadedOnDevice(boolean))`(boolean downloadedOnDevice)` Sets a boolean value to indicate if music video is downloaded on device or not.                                                                                                                                                      |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setDurationMillis](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setDurationMillis(long))`(long durationMillis)` Sets the duration of the music video.                                                                                                                                                                                                                  |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setEntityId](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setEntityId(java.lang.String))`(`[String](https://developer.android.com/reference/java/lang/String.html)` entityId)` Sets content id of the entity.                                                                                                                                                          |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setExplicitContent](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setExplicitContent(boolean))`(boolean explicitContent)` Sets a boolean value to indicate if music video has explicit content or not.                                                                                                                                                                  |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setInfoPageUri](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setInfoPageUri(android.net.Uri))`(`[Uri](https://developer.android.com/reference/android/net/Uri.html)` infoPageUri)` Sets the info page uri of the music video.                                                                                                                                          |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setLastEngagementTimeMillis](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setLastEngagementTimeMillis(long))`(long lastEngagementTimeMillis)` Sets last engagement time of the entity, in milliseconds since Epoch.                                                                                                                                                    |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setName](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setName(java.lang.String))`(`[String](https://developer.android.com/reference/java/lang/String.html)` name)` Sets the name of the entity.                                                                                                                                                                        |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setPlayBackUri](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setPlayBackUri(android.net.Uri))`(`[Uri](https://developer.android.com/reference/android/net/Uri.html)` playBackUri)` Sets the play back uri of the music video.                                                                                                                                          |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setProgressPercentComplete](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setProgressPercentComplete(int))`(int progressPercentComplete)` Sets progress percent complete of the audio entity.                                                                                                                                                                           |
| [MusicVideoEntity.Builder](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder) | `@`[CanIgnoreReturnValue](https://errorprone.info/api/latest/com/google/errorprone/annotations/CanIgnoreReturnValue.html) [setViewCount](https://developer.android.com/reference/com/google/android/engage/audio/datamodel/MusicVideoEntity.Builder#setViewCount(java.lang.String))`(`[String](https://developer.android.com/reference/java/lang/String.html)` viewCount)` Sets the number of views of the music video.                                                                                                                                         |

## Public constructors

### Builder

```
public Builder()
```  

## Public methods

### addArtist

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder addArtist(String artist)
```

Adds artist of the music video.

Optional.  

### addArtists

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder addArtists(List<String> artists)
```

Adds the list of artists of the music video.

Optional.  

### addContentRating

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder addContentRating(String contentRating)
```

Adds the content rating of the music video.

Optional.  

### addContentRatings

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder addContentRatings(List<String> contentRatings)
```

Adds the list of content ratings of the music video.

Optional.  

### addPosterImage

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder addPosterImage(Image image)
```

Add a poster image of the entity.

Required.  

### addPosterImages

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder addPosterImages(List<Image> images)
```

Add poster images of the entity.

Required.  

### build

```
public MusicVideoEntity build()
```  

### setDescription

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setDescription(String description)
```

Adds the description of the audio entity.

Optional.  

### setDownloadedOnDevice

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setDownloadedOnDevice(boolean downloadedOnDevice)
```

Sets a boolean value to indicate if music video is downloaded on device or not.

Optional.  

### setDurationMillis

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setDurationMillis(long durationMillis)
```

Sets the duration of the music video.

Required.  

### setEntityId

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setEntityId(String entityId)
```

Sets content id of the entity.

Optional.  

### setExplicitContent

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setExplicitContent(boolean explicitContent)
```

Sets a boolean value to indicate if music video has explicit content or not.

Optional.  

### setInfoPageUri

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setInfoPageUri(Uri infoPageUri)
```

Sets the info page uri of the music video.

Optional.  

### setLastEngagementTimeMillis

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setLastEngagementTimeMillis(long lastEngagementTimeMillis)
```

Sets last engagement time of the entity, in milliseconds since Epoch.

Optional.  

### setName

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setName(String name)
```

Sets the name of the entity.

Required.  

### setPlayBackUri

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setPlayBackUri(Uri playBackUri)
```

Sets the play back uri of the music video.

Required.  

### setProgressPercentComplete

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setProgressPercentComplete(int progressPercentComplete)
```

Sets progress percent complete of the audio entity.

Optional  

### setViewCount

```
@CanIgnoreReturnValue
public MusicVideoEntity.Builder setViewCount(String viewCount)
```

Sets the number of views of the music video.

Optional.