protected static final class MediaPresentationDescriptionParser.ContentProtectionsBuilder extends Object implements Comparator<ContentProtection>
ContentProtection
elements for an AdaptationSet
.
If child Representation elements contain ContentProtection elements, then it is required that they all define the same ones. If they do, the ContentProtection elements are bubbled up to the AdaptationSet. Child Representation elements defining different ContentProtection elements is considered an error.
Modifier | Constructor and Description |
---|---|
protected |
ContentProtectionsBuilder() |
Modifier and Type | Method and Description |
---|---|
void |
addAdaptationSetProtection(ContentProtection contentProtection)
Adds a
ContentProtection found in the AdaptationSet element. |
void |
addRepresentationProtection(ContentProtection contentProtection)
Adds a
ContentProtection found in a child Representation element. |
ArrayList<ContentProtection> |
build()
Returns the final list of consistent
ContentProtection elements. |
int |
compare(ContentProtection first,
ContentProtection second) |
void |
endRepresentation()
Should be invoked after processing each child Representation element, in order to apply
consistency checks.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
public void addAdaptationSetProtection(ContentProtection contentProtection)
ContentProtection
found in the AdaptationSet element.contentProtection
- The ContentProtection
to add.public void addRepresentationProtection(ContentProtection contentProtection)
ContentProtection
found in a child Representation element.contentProtection
- The ContentProtection
to add.public void endRepresentation()
public ArrayList<ContentProtection> build()
ContentProtection
elements.public int compare(ContentProtection first, ContentProtection second)
compare
in interface Comparator<ContentProtection>