All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class ejmf.examples.mixer.SimpleMixer

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----com.sun.java.swing.JComponent
                           |
                           +----com.sun.java.swing.JPanel
                                   |
                                   +----ejmf.examples.mixer.SimpleMixer

public class SimpleMixer
extends JPanel
implements MultiPlayerListener
A SimpleMixer displays a collection of tracks using two views. One view is a table that contains media locator for a Player and media's start and playing time. The latter two fields may be manipulated in the table.

The second view is a slider for each track. As the slider is manipulated, the media start time is changed.

A SimpleMixer may also display a ViewingPanel in which the visual component of each Track's Player appears.

The SimpleMixer interface provides a way to open and close media files, as well as start and stop the play of media.


Constructor Index

 o SimpleMixer(int)
Create a SimpleMixer for a given number of tracks.

Method Index

 o createMenuBar()
 o getMenuBar()
 o getNumberOfTracks()
 o getTrack(int)
Get a track associated with the given index.
 o multiPlayerUpdate(int)
Called in response to state changes in MultiPlayer Updates the state of Control menu items.

Constructors

 o SimpleMixer
 public SimpleMixer(int numberOfTracks)
Create a SimpleMixer for a given number of tracks.

Parameters:
numberOfTracks - Number of tracks displayed and controlled by SimpleMixer.

Methods

 o getMenuBar
 public JMenuBar getMenuBar()
Returns:
SimpleMixer's menu bar
 o createMenuBar
 protected JMenuBar createMenuBar()
 o getNumberOfTracks
 public int getNumberOfTracks()
Returns:
the number of tracks associated with this SimpleMixer
 o getTrack
 public Track getTrack(int index) throws IllegalArgumentException
Get a track associated with the given index.

Parameters:
index - Index of desired track
Returns:
a Track.
See Also:
Track
 o multiPlayerUpdate
 public void multiPlayerUpdate(int state)
Called in response to state changes in MultiPlayer Updates the state of Control menu items.

Parameters:
One - of MultiPlatyer's states.

All Packages  Class Hierarchy  This Package  Previous  Next  Index