Added in API level 21
Builder
open class Builder
kotlin.Any | |
↳ | android.media.MediaDescription.Builder |
Builder for MediaDescription
objects.
Summary
Public constructors | |
---|---|
Builder() Creates an initially empty builder. |
Public methods | |
---|---|
open MediaDescription! |
build() Build |
open MediaDescription.Builder! |
setDescription(description: CharSequence?) Sets the description. |
open MediaDescription.Builder! |
Sets a bundle of extras. |
open MediaDescription.Builder! |
setIconBitmap(icon: Bitmap?) Sets the icon. |
open MediaDescription.Builder! |
setIconUri(iconUri: Uri?) Sets the icon uri. |
open MediaDescription.Builder! |
setMediaId(mediaId: String?) Sets the media id. |
open MediaDescription.Builder! |
setMediaUri(mediaUri: Uri?) Sets the media uri. |
open MediaDescription.Builder! |
setSubtitle(subtitle: CharSequence?) Sets the subtitle. |
open MediaDescription.Builder! |
setTitle(title: CharSequence?) Sets the title. |
Public constructors
Public methods
build
Added in API level 21
open fun build(): MediaDescription!
Build MediaDescription
.
Return | |
---|---|
MediaDescription! |
a new media description. |
setDescription
Added in API level 21
open fun setDescription(description: CharSequence?): MediaDescription.Builder!
Sets the description.
Parameters | |
---|---|
description |
CharSequence?: A description suitable for display to the user or null. |
Return | |
---|---|
MediaDescription.Builder! |
this |
setExtras
Added in API level 21
open fun setExtras(extras: Bundle?): MediaDescription.Builder!
Sets a bundle of extras.
Parameters | |
---|---|
extras |
Bundle?: The extras to include with this description or null. |
Return | |
---|---|
MediaDescription.Builder! |
this |
setIconBitmap
Added in API level 21
open fun setIconBitmap(icon: Bitmap?): MediaDescription.Builder!
Sets the icon.
Parameters | |
---|---|
icon |
Bitmap?: A Bitmap icon suitable for display to the user or null. |
Return | |
---|---|
MediaDescription.Builder! |
this |
setIconUri
Added in API level 21
open fun setIconUri(iconUri: Uri?): MediaDescription.Builder!
Sets the icon uri.
Parameters | |
---|---|
iconUri |
Uri?: A Uri for an icon suitable for display to the user or null. |
Return | |
---|---|
MediaDescription.Builder! |
this |
setMediaId
Added in API level 21
open fun setMediaId(mediaId: String?): MediaDescription.Builder!
Sets the media id.
Parameters | |
---|---|
mediaId |
String?: The unique id for the item or null. |
Return | |
---|---|
MediaDescription.Builder! |
this |
setMediaUri
Added in API level 23
open fun setMediaUri(mediaUri: Uri?): MediaDescription.Builder!
Sets the media uri.
Parameters | |
---|---|
mediaUri |
Uri?: The content's Uri for the item or null. |
Return | |
---|---|
MediaDescription.Builder! |
this |
setSubtitle
Added in API level 21
open fun setSubtitle(subtitle: CharSequence?): MediaDescription.Builder!
Sets the subtitle.
Parameters | |
---|---|
subtitle |
CharSequence?: A subtitle suitable for display to the user or null. |
Return | |
---|---|
MediaDescription.Builder! |
this |
setTitle
Added in API level 21
open fun setTitle(title: CharSequence?): MediaDescription.Builder!
Sets the title.
Parameters | |
---|---|
title |
CharSequence?: A title suitable for display to the user or null. |
Return | |
---|---|
MediaDescription.Builder! |
this |