The VoiceSegment class

The VoiceSegment class is used to represent a voice segment stored on the Blueworx Voice Response server. This segment can contain pre-recorded speech to be used by the voice application, or it can be empty in preparation for obtaining input from the caller. VoiceSegments can be deleted, imported and exported dynamically, see Handling voice segments dynamically.

To distinguish the voice segment from other segments on the server, each VoiceSegment object has a name, a category and a locale.

The constructor methods for this class are:
VoiceSegment()
Constructs an voice segment object with default properties, category="", locale=null and name="". You can set these properties later using the methods setCategory(), setName() and setLocale() (inherited from MediaType).
VoiceSegment(java.lang.String category, java.lang.String name)
Constructs a voice segment object with the specified category and name, and default locale.
VoiceSegment(java.lang.String category, java.lang.String name, java.util.Locale locale)
Constructs a voice segment object with the specified category, name and locale.
Example:
public class InApp extends WVRApplication {
  .
  .
  .
  // Create the Welcome and Difficulties segment objects
  public VoiceSegment vs_welcome  = new VoiceSegment("App1Segments", "Welcome");
  public VoiceSegment vs_difficulties  = new VoiceSegment("App1Segments", "Difficulties");
  .
  .
  .
}
To manage your voice segments, specify for each one a category defined in your Voice Segment Database and a unique label identifying the voice segment.