Holger's Java API

## com.antelmann.sound
Enum SampleSounds

    java.lang.Object
      java.lang.Enum<SampleSounds>
          com.antelmann.sound.SampleSounds

All Implemented Interfaces:
  Timed, Serializable, Comparable<SampleSounds>

    public enum SampleSounds

extends Enum<SampleSounds>
implements Timed

SampleSounds provides some sample sounds that are included in the standard antelmann.jar file. The methods make a best attempt to play a given sound once; any exceptions are ignored.

Author:
  Holger Antelmann

Enum Constant Summary
`DERANGED` represents the sound "deranged" included in the antelmann.jar file
`DISAPPOINTED` represents the sound "disappointed" included in the antelmann.jar file
`DOH` represents the sound "doh" included in the antelmann.jar file
`MESSAGE4U` represents the sound "there is a message for you" included in the antelmann.jar file
`NI` represents the sound "ni" included in the antelmann.jar file
`RAGTIME` represents a midi file playing a ragtime song included in the antelmann.jar file
`REGISTER` represents the sound "cashregister" included in the antelmann.jar file
`RING` represents the sound "ring" included in the antelmann.jar file
`TYPING` represents the sound "type" included in the antelmann.jar file

Field Summary

Fields inherited from interface com.antelmann.calendar.Timed
`COMPARATOR, DATE_EXTRACTOR`

Method Summary
`URL` `getResource()`
`long` `getTime()` provides the duration of the sound before it has to be loaded
`void` `play()`
`void` `playAndWait()`
`static SampleSounds` `valueOf(String name)` Returns the enum constant of this type with the specified name.
`static SampleSounds[]` `values()` Returns an array containing the constants of this enum type, in the order they are declared.

Methods inherited from class java.lang.Enum
`clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

Methods inherited from class java.lang.Object
`getClass, notify, notifyAll, wait, wait, wait`

Enum Constant Detail

### DOH

    public static final SampleSounds DOH

  represents the sound "doh" included in the antelmann.jar file

### MESSAGE4U

    public static final SampleSounds MESSAGE4U

  represents the sound "there is a message for you" included in the antelmann.jar file

### NI

    public static final SampleSounds NI

  represents the sound "ni" included in the antelmann.jar file

### RING

    public static final SampleSounds RING

  represents the sound "ring" included in the antelmann.jar file

### DISAPPOINTED

    public static final SampleSounds DISAPPOINTED

  represents the sound "disappointed" included in the antelmann.jar file

### DERANGED

    public static final SampleSounds DERANGED

  represents the sound "deranged" included in the antelmann.jar file

### RAGTIME

    public static final SampleSounds RAGTIME

  represents a midi file playing a ragtime song included in the antelmann.jar file

### REGISTER

    public static final SampleSounds REGISTER

  represents the sound "cashregister" included in the antelmann.jar file

### TYPING

    public static final SampleSounds TYPING

  represents the sound "type" included in the antelmann.jar file

Method Detail

### values

    public static SampleSounds[] values()

  Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:

      for (SampleSounds c : SampleSounds.values())
          System.out.println(c);

  Returns:
    an array containing the constants of this enum type, in the order they are declared

### valueOf

    public static SampleSounds valueOf(String name)

  Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

  Parameters:
    `name` - the name of the enum constant to be returned.
  Returns:
    the enum constant with the specified name
  Throws:
    `IllegalArgumentException` - if this enum type has no constant with the specified name
    `NullPointerException` - if the argument is null

### getResource

    public URL getResource()

### getTime

    public long getTime()

  provides the duration of the sound before it has to be loaded

  Specified by:
    `getTime` in interface `Timed`

### play

    public void play()

  See Also:
    `SoundPlayer.play(URL)`

### playAndWait

    public void playAndWait()

  See Also:
    `SoundPlayer.playAndWait(URL)`

(c) Holger Antelmann since 2001- all rights reserved (contact: info@antelmann.com)
see www.antelmann.com/developer for further details and available downloads