|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--net.rim.plazmic.mediaengine.MediaManager
Abstract class for downloading media content from the Internet
or local storage and provides the implementation for MediaLoader methods.
MediaPlayer| Field Summary |
| Constructor Summary | ||
MediaManager()
The default constructor. |
||
MediaManager(Connector c)
Creates a MediaManager instance given a connector.
|
||
MediaManager(Connector c,
boolean enableRelative)
Creates a MediaManager instance given a connector and a
boolean that indicates whether or not relative URLs are enabled.
|
||
| Method Summary | ||
void |
addMediaListener(MediaListener listener)
Adds a listener to the media. |
|
void |
cancel()
Cancels the current download if one exists. |
|
Object |
createMedia(String url)
Loads media content from a given URL. |
|
void |
createMediaLater(String uri)
Loads media content for later given a Uniform Resource Indicator (URI). |
|
void |
dispose()
Disposes the download if one exists. |
|
Connector |
getConnector()
Returns the connector for this MediaManager.
|
|
Connector |
getDefaultConnector()
Returns the default connector associated with this MediaManager. |
|
void |
removeMediaListener(MediaListener listener)
Removes a listener from the media. |
|
protected String |
resolveURL(String url)
Resolves the specified URL. |
|
void |
setConnector(Connector connector)
Sets the connector for this MediaManager.
|
|
void |
setProperty(String name,
String value)
Set connection properties. |
|
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
| Constructor Detail |
public MediaManager(Connector c)
MediaManager instance given a connector.
c - The connector used to create the MediaManager.public MediaManager(Connector c, boolean enableRelative)
MediaManager instance given a connector and a
boolean that indicates whether or not relative URLs are enabled.
c - The connector used to create the MediaManager.enableRelative - A boolean indicating whether or not relative URLs
are allowed.| Method Detail |
public void setConnector(Connector connector)
MediaManager.
connector - The connector to set.public Connector getConnector()
MediaManager.
public Connector getDefaultConnector()
public void setProperty(String name, String value) throws IllegalArgumentException
name - property namevalue - property valueIllegalArgumentException - exception if the property is not supportedprotected String resolveURL(String url)
url - The URL to be resolved.public void addMediaListener(MediaListener listener)
listener - The listener to add.public void removeMediaListener(MediaListener listener)
listener - The listener to remove.public Object createMedia(String url) throws IOException, MediaException
url - A string representing the URL.IOException - Thrown if the i/o error occured during the download
or parsing of the data.MediaException - Thrown if the media is not supported or the download has been cancelled.public void createMediaLater(String uri)
uri - A string representing the URI.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright 1999-2002 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2000 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A. All Rights Reserved.
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.