|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ocap.media.MediaTimer
public class MediaTimer
This is a timer class that counts time based on a media time of a specified Player. A media time is specified by the JMF specification. An application can specify a range between a first time and a last time. When a current media time exceeds this range, this timer fires and calls a MediaTimerListener.notify() method. I.e., when a current media time passes the last time, this timer fires and calls the notify() method with MEDIA_WENTOFF_LAST event. On the other hand, when a current media time passes the first time in a reverse playback or a skip playback, this timer fires and calls the notify() method with MEDIA_WENTOFF_FIRST event.
| Constructor Summary | |
|---|---|
MediaTimer(Player p,
MediaTimerListener listener)
Constructor to make a MediaTimer object that counts time based on the media time line of the specified Player. |
|
| Method Summary | |
|---|---|
Time |
getFirstTime()
Get a first time that was set to this MediaTimer object. |
Time |
getLastTime()
Get a last time that was set to this MediaTimer object. |
Player |
getPlayer()
Get a Player that was tied to this MediaTimer object by a constructor. |
void |
setFirstTime(Time time)
Set a first time of a time range. |
void |
setLastTime(Time time)
Set a last time of a time range. |
void |
start()
Start this MediaTimer object. |
void |
stop()
Stop this MediaTimer object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MediaTimer(Player p,
MediaTimerListener listener)
p - a JMF Player.| Method Detail |
|---|
public void setFirstTime(Time time)
time - a time to go off.public void setLastTime(Time time)
time - a time to go off.public Time getFirstTime()
public Time getLastTime()
public void start()
public void stop()
public Player getPlayer()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||