Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
SDK
/
exoplayer
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
7ef31e22
authored
Aug 17, 2020
by
olly
Committed by
kim-vde
Aug 17, 2020
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Tweak DefaultMediaSourceFactory documentation
PiperOrigin-RevId: 327000958
parent
02ed809a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
7 deletions
library/core/src/main/java/com/google/android/exoplayer2/source/DefaultMediaSourceFactory.java
library/core/src/main/java/com/google/android/exoplayer2/source/DefaultMediaSourceFactory.java
View file @
7ef31e22
...
@@ -25,6 +25,7 @@ import androidx.annotation.Nullable;
...
@@ -25,6 +25,7 @@ import androidx.annotation.Nullable;
import
com.google.android.exoplayer2.C
;
import
com.google.android.exoplayer2.C
;
import
com.google.android.exoplayer2.ExoPlayerLibraryInfo
;
import
com.google.android.exoplayer2.ExoPlayerLibraryInfo
;
import
com.google.android.exoplayer2.MediaItem
;
import
com.google.android.exoplayer2.MediaItem
;
import
com.google.android.exoplayer2.MediaItem.DrmConfiguration
;
import
com.google.android.exoplayer2.drm.DefaultDrmSessionManager
;
import
com.google.android.exoplayer2.drm.DefaultDrmSessionManager
;
import
com.google.android.exoplayer2.drm.DrmSessionManager
;
import
com.google.android.exoplayer2.drm.DrmSessionManager
;
import
com.google.android.exoplayer2.drm.FrameworkMediaDrm
;
import
com.google.android.exoplayer2.drm.FrameworkMediaDrm
;
...
@@ -80,9 +81,9 @@ import java.util.Map;
...
@@ -80,9 +81,9 @@ import java.util.Map;
*
*
* <h3>DrmSessionManager creation for protected content</h3>
* <h3>DrmSessionManager creation for protected content</h3>
*
*
* <p>For a media item with a
valid {@link
* <p>For a media item with a
{@link DrmConfiguration}, a {@link DefaultDrmSessionManager} is
* c
om.google.android.exoplayer2.MediaItem.DrmConfiguration}, a {@link DefaultDrmSessionManager} is
* c
reated based on that configuration. The following setter can be used to optionally configure the
* creat
ed. The following setter can be used to optionally configure the creat
ion:
* creation:
*
*
* <ul>
* <ul>
* <li>{@link #setDrmHttpDataSourceFactory(HttpDataSource.Factory)}: Sets the data source factory
* <li>{@link #setDrmHttpDataSourceFactory(HttpDataSource.Factory)}: Sets the data source factory
...
@@ -90,10 +91,8 @@ import java.util.Map;
...
@@ -90,10 +91,8 @@ import java.util.Map;
* DefaultHttpDataSourceFactory}).
* DefaultHttpDataSourceFactory}).
* </ul>
* </ul>
*
*
* <p>For media items without a drm configuration {@link DrmSessionManager#DUMMY} is used. To use an
* <p>For media items without a {@link DrmConfiguration}, the {@link DrmSessionManager} passed to
* alternative dummy, apps can pass a drm session manager to {@link
* {@link #setDrmSessionManager(DrmSessionManager)} will be used.
* #setDrmSessionManager(DrmSessionManager)} which will be used for all items without a drm
* configuration.
*
*
* <h3>Ad support for media items with ad tag uri</h3>
* <h3>Ad support for media items with ad tag uri</h3>
*
*
...
@@ -235,6 +234,13 @@ public final class DefaultMediaSourceFactory implements MediaSourceFactory {
...
@@ -235,6 +234,13 @@ public final class DefaultMediaSourceFactory implements MediaSourceFactory {
return
this
;
return
this
;
}
}
/**
* Sets the {@link DrmSessionManager} to use for media items that do not specify a {@link
* DrmConfiguration}. The default value is {@link DrmSessionManager#DUMMY}.
*
* @param drmSessionManager The {@link DrmSessionManager}.
* @return This factory, for convenience.
*/
@Override
@Override
public
DefaultMediaSourceFactory
setDrmSessionManager
(
public
DefaultMediaSourceFactory
setDrmSessionManager
(
@Nullable
DrmSessionManager
drmSessionManager
)
{
@Nullable
DrmSessionManager
drmSessionManager
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment