public abstract class BaseMediaSource extends Object implements MediaSource
MediaSource interface.MediaSourceMediaSource.Output| Modifier and Type | Field and Description |
|---|---|
protected long |
contentLength |
protected String |
etag |
protected DateTime |
lastModified |
protected String |
mediaType |
protected String |
name |
| Modifier | Constructor and Description |
|---|---|
protected |
BaseMediaSource(String mediaType)
Constructs a new BaseMediaSource of the specified content type.
|
| Modifier and Type | Method and Description |
|---|---|
long |
getContentLength()
Returns the length (in bytes) of the media source.
|
String |
getContentType() |
String |
getEtag()
Returns the entity tag (etag) value associated with the media content
or
null if unknown. |
DateTime |
getLastModified()
Returns the last modification time of the media content or
null
if unknown. |
String |
getName() |
void |
setContentLength(long contentLength) |
void |
setEtag(String etag) |
void |
setLastModified(DateTime lastModified) |
void |
setName(String name) |
protected final String mediaType
protected long contentLength
protected DateTime lastModified
protected String name
protected String etag
protected BaseMediaSource(String mediaType)
public String getContentType()
getContentType in interface javax.activation.DataSourcepublic void setName(String name)
public String getName()
getName in interface javax.activation.DataSourcepublic void setLastModified(DateTime lastModified)
public DateTime getLastModified()
MediaSourcenull
if unknown.getLastModified in interface MediaSourcepublic void setContentLength(long contentLength)
public long getContentLength()
MediaSourcegetContentLength in interface MediaSourcepublic void setEtag(String etag)
public String getEtag()
MediaSourcenull if unknown.getEtag in interface MediaSourceCopyright © 2012. All Rights Reserved.