List of usage examples for android.media MediaDescription getMediaUri
public @Nullable Uri getMediaUri()
From source file:org.opensilk.video.data.MediaDescriptionUtil.java
public static Uri getMediaUri(MediaDescription description) { if (VersionUtils.hasApi23()) { return description.getMediaUri(); } else {/*from w ww . ja v a 2 s .com*/ MediaMetaExtras metaExtras = MediaMetaExtras.from(description); return metaExtras.getMediaUri(); } }
From source file:org.opensilk.video.data.MediaDescriptionUtil.java
public static MediaDescription.Builder newBuilder(MediaDescription description) { MediaDescription.Builder bob = new MediaDescription.Builder().setIconUri(description.getIconUri()) .setMediaId(description.getMediaId()).setExtras(description.getExtras()) .setSubtitle(description.getSubtitle()).setTitle(description.getTitle()) .setDescription(description.getDescription()); if (VersionUtils.hasApi23()) { bob.setMediaUri(description.getMediaUri()); }/*from w w w.j a va 2s.com*/ return bob; }