Cisco Cisco Unified Customer Voice Portal 10.5(1) Developer's Guide

Page of 79
C
HAPTER 
9:
 
C
ONFIGURABLE
 E
LEMENTS
 
 
C
ISCO 
CVP V
OICE
XML 3.1
 
 
  
Programmer 
Guide 
 
Chapter 9: Configurable Elements 
The large array of CVP VoiceXML Elements bundled with Cisco CVP VoiceXML software 
encapsulate a lot of functionality a typical voice application requires. There are, however, 
situations where more customized, proprietary, or robust elements are desired. This is certainly 
the case with action and decision elements, which tend to be highly specialized for interfacing 
with proprietary backend systems or implementing custom business logic. To a lesser extent this 
applies for voice elements as well. Cisco CVP VoiceXML has tried to provide pre-built voice 
elements that cover most of what a typical voice application requires. There is always the option 
of using VoiceXML insert elements to handle a situation that there are no voice elements to 
manage. The disadvantages of VoiceXML insert elements, however, are in their inconsistencies 
across various voice browsers, the size they can be before management becomes burdensome, 
the difficulty of interacting with backend systems, and their overall performance. Custom voice 
elements are the best way to achieve these goals as they are fast, use the CVP VoiceXML Voice 
Foundation Classes (VFCs) that work consistently across multiple voice browsers, and are built 
with Java, so complex calculations and integrations are simple.  
Cisco CVP VoiceXML software was designed to be modular without compromising integration. 
Custom elements are integrated into both CVP VoiceXML Server and CVP VoiceXML Studio 
as easily as CVP VoiceXML Elements are. They can be deployed for a specific application or 
shared across all applications and are configured in the Studio alongside CVP VoiceXML 
Elements, including supporting dynamic configurations. With such seamless integration and 
effortless deployment, a developer can, over time, create entire libraries of custom elements to 
use for their voice applications or potentially for resale.  
Due to the requirements to integrate with both Studio and the Server, configurable elements can 
only be constructed using the Java API. This is not to be confused with standard action and 
decision elements, both of which can be constructed using both Java and XML APIs. It is the 
configuration of a configurable element that places demands that can only be met by the Java 
API. Building standard action and decision elements are fully explained in Chapter 7: Standard 
Action Elements and Ch
apter 8: Standard Decision Elements. 
This chapter describes in detail how to create custom voice, action, and decision elements and 
integrate them into both Studio and the Server. 
Design 
Configurable elements are built by extending an abstract Java class. This base class lays out the 
methods used to identify the element’s configuration, how it is executed, and any utility methods 
available to it. The developer simply implements the appropriate methods and uses the Java API 
provided to build the element. Within the execution method, the developer is then free to use 
Java in any way possible, such as creating a complex class hierarchy, accessing files or backend 
systems, utilizing third party libraries, even communicating with external systems via HTTP or 
RMI. Voice elements must extend 
VoiceElementBase
, action elements 
ActionElementBase
 
 
Copyright 2001 - 2005 Audium Corporation.  All Rights Reserved. 10/05
 
48