Interface sound


public interface sound

sound.js contains methods necessary to play a URL containing a sound file


Method Summary
 int getVolumeLevel()
          Obtains the current system audio volume level
 boolean playSoundAsync(java.lang.String url)
          Plays a WAV file specified by the URL
 boolean setVolumeLevel(byte level)
          Sets the current system audio volume level
 

Method Detail

playSoundAsync

public boolean playSoundAsync(java.lang.String url)
Plays a WAV file specified by the URL

Parameters:
url - The WAV filename to play
Returns:
Returns whether the operation was successful
WATA Integration
Host ApplicationN/A
Host AppletSoundHostApplet
FlowThe host applet will use the Applet AudioClip functionality to play the specified URL

getVolumeLevel

public int getVolumeLevel()
Obtains the current system audio volume level

Returns:
Returns the current system volume level. Returns -1 if the level cannot be determined
WATA Integration
Host Applicationcom.ibm.retail.saf.wata.host.settings.SettingsAgentManager
Host AppletSettingsApplet
FlowUses: set (level) os/sound/volume.percent

setVolumeLevel

public boolean setVolumeLevel(byte level)
Sets the current system audio volume level

Parameters:
level - The percentage to set the volume level
Returns:
Returns whether the operation was successful
WATA Integration
Host Applicationcom.ibm.retail.saf.wata.host.settings.SettingsAgentManager
Host AppletSettingsApplet
FlowUses: get os/sound/volume.percent