public class Sample
extends java.lang.Object
Constructor | Description |
---|---|
Sample(Sound aSound,
int index) |
Constructor that takes a sound and an index
|
Modifier and Type | Method | Description |
---|---|---|
Sound |
getSound() |
Method to get this sample's sound object
|
int |
getValue() |
Method to get the sample value
|
void |
setValue(double newValue) |
Method to set the sample value
|
void |
setValue(int newValue) |
Method to set the sample value
|
java.lang.String |
toString() |
Obtains a string representation of this Sample
|
public Sample(Sound aSound, int index)
aSound
- the soundindex
- the indexpublic java.lang.String toString()
toString
in class java.lang.Object
public Sound getSound()
public int getValue() throws SoundException
SoundException
public void setValue(int newValue) throws SoundException
newValue
- the new value to storeSoundException
public void setValue(double newValue) throws SoundException
newValue
- the new value to storeSoundException