edu.stanford.hci.r3.actions.types
Class PlaySoundAction

java.lang.Object
  extended by edu.stanford.hci.r3.actions.types.PlaySoundAction
All Implemented Interfaces:
R3Action

public class PlaySoundAction
extends java.lang.Object
implements R3Action

Play a sound file. It must be available on the local file system, wherever this action ends up.

This software is distributed under the BSD License.


Nested Class Summary
static interface PlaySoundAction.PlaySoundListener
           
 
Constructor Summary
PlaySoundAction(java.io.File soundFile)
           
 
Method Summary
 void addStopListener(PlaySoundAction.PlaySoundListener psl)
           
 void invoke()
          Invoke this action on the local machine.
 void pause()
           
 void stop()
          Stops the audio player and disposes resources.
 void unpause()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface edu.stanford.hci.r3.actions.R3Action
toString
 

Constructor Detail

PlaySoundAction

public PlaySoundAction(java.io.File soundFile)
Parameters:
soundFile -
Method Detail

addStopListener

public void addStopListener(PlaySoundAction.PlaySoundListener psl)

invoke

public void invoke()
Description copied from interface: R3Action
Invoke this action on the local machine. If you want to invoke this on a remote machine, you will need to send it across the wire. That machine will then unserialize the action object and call invoke() on ITS local machine.

Specified by:
invoke in interface R3Action
See Also:
R3Action.invoke()

pause

public void pause()

stop

public void stop()
Stops the audio player and disposes resources.


unpause

public void unpause()

Copyright 2006 Stanford University