Class SoundSample

java.lang.Object
  extended bySoundSample

public class SoundSample
extends java.lang.Object

Class that represents a sample of a sound. It knows what sound object it comes from and knows what frame number this sample is in the sound object. Copyright Georgia Institute of Technology 2004

Author:
Barb Ericson ericson@cc.gatech.edu

Constructor Summary
SoundSample(SimpleSound sound, int frameNumber)
          Constructor that takes a sound and valueArray
 
Method Summary
 int getValue()
          Method to get the value of this sample as in int and handle the possible sound exception
 void setValue(int value)
          Method to set the value of this sample and handle the sound exception
 java.lang.String toString()
          Method to return a string with the information about this object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SoundSample

public SoundSample(SimpleSound sound,
                   int frameNumber)
Constructor that takes a sound and valueArray

Parameters:
sound - the sound object this sample comes from
frameNumber - the frameNumber of this sample in the sound
Method Detail

getValue

public int getValue()
Method to get the value of this sample as in int and handle the possible sound exception

Returns:
the value of this sample as an int

setValue

public void setValue(int value)
Method to set the value of this sample and handle the sound exception

Parameters:
value - the value to use

toString

public java.lang.String toString()
Method to return a string with the information about this object

Returns:
a string with information about this object