|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.bramosystems.oss.player.core.client.playlist.MRL
public class MRL
Media Resource Locator that holds multiple alternative URLs of the same media resource (probably in different formats).
Constructor Summary | |
---|---|
MRL()
Constructs MRL object |
|
MRL(java.util.List<java.lang.String> urls)
Constructs MRL object with the specified URLs |
|
MRL(java.lang.String... urls)
Constructs MRL object with the specified URLs |
|
MRL(java.lang.String name,
java.lang.String author)
Constructs MRL object with the specified name and author |
Method Summary | |
---|---|
void |
addURL(java.lang.String... urls)
Adds the specified URLs to this locator |
java.lang.String |
getAuthor()
Returns the author of the media resource |
java.lang.String |
getCurrentResource()
Return the current URL. |
java.lang.String |
getName()
Returns a descriptive name of the media resource |
java.lang.String |
getNextResource(boolean roll)
Returns the next alternative URL of the media |
java.lang.String |
getResource(int index)
Returns the resource URL at the specified index |
int |
getResourceCount()
Returns the number of URLs in this locator |
void |
setAuthor(java.lang.String author)
Sets the author of the media resource |
void |
setName(java.lang.String name)
Assigns a descriptive name for the media resource |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public MRL()
public MRL(java.lang.String name, java.lang.String author)
name
and author
name
- the descriptive name of the media resourceauthor
- the author of the media resourcepublic MRL(java.lang.String... urls)
urls
- URLs of the mediapublic MRL(java.util.List<java.lang.String> urls)
urls
- URLs of the mediaMethod Detail |
---|
public void addURL(java.lang.String... urls)
urls
- URLs of the mediapublic java.lang.String getNextResource(boolean roll)
roll
- true
if an end-of-list should roll over to the first URL
java.lang.IndexOutOfBoundsException
- if end-of-list is reached and roll
is falsepublic java.lang.String getCurrentResource()
getNextResource(boolean)
method call
public int getResourceCount()
public java.lang.String getResource(int index)
index
index
- the index of the required resource URL
java.lang.IndexOutOfBoundsException
- if the index is out of rangepublic java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String getAuthor()
public void setAuthor(java.lang.String author)
author
- the author of the media resourcepublic java.lang.String getName()
public void setName(java.lang.String name)
name
- a descriptive name of the media resource
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |