com.cisco.jtapi.extensions
Interface CiscoBaseMediaTerminal

All Superinterfaces:
CiscoObjectContainer, CiscoTerminal, javax.telephony.Terminal

public interface CiscoBaseMediaTerminal
extends CiscoTerminal

Introduction

A CiscoBaseMediaTerminal is a special kind of CiscoTerminal that allows applications to terminate RTP media streams. Unlike a CiscoTerminal, a CiscoBaseMediaTerminal does not represent a physical telephony endpoint, which is observable and controllable in a third-party manner. Instead, a CiscoBaseMediaTerminal is a logical telephony endpoint, which may be associated with any application that wants to terminate media. Such applications include voice messaging systems, interactive voice response (IVR), and softphones.

NOTE: Only CTIPorts and Route Points appear as CiscoBaseMediaTerminals through JTAPI.

Terminating media is a two-step process. To terminate media for a particular terminal, an application first adds an observer that implements the CiscoTerminalObserver interface using the Terminal.addObserver method. Finally, the application registers the IP address and port number to which incoming RTP streams for the terminal should be directed, by using the CiscoBaseMediaTerminal.register method.

To supply an IP address and port number dynamically on a per-call basis, applications must register by only providing the capabilities that they support. Applications must react to the CiscoMediaOpenLogicalChannelEv that gets sent whenever media gets established. Applications registering with this type must be aware that, when this event is received, the far end and the local end may not be able to perform any feature operation unless media is established. If applications fail to respond to this event within the specified time, the call may get dropped.

See Also:
CiscoTerminal

Field Summary
static int DYNAMIC_MEDIA_REGISTRATION
          Applications that are interested in dynamic media termination need to register with this type and pass in the capabilities that the application supports in the registration request.
static int DYNAMIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT
          Applications that are interested in dynamic media termination need to register with this type and pass in the capabilities that the application supports in the registration request.
static int NO_MEDIA_REGISTRATION
          Applications that are not interested in media termination need to register with this type and pass in a null value for CiscoMediaCapability in the registration request.
static int STATIC_MEDIA_REGISTRATION
          Applications that are interested in static media termination need to register with this type and pass in the capabilities that the application supports in the registration request.
static int STATIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT
          Applications that are interested in static media termination with support for SIP Trunk Early Offer need to register with this type and pass in the capabilities that the application supports in the registration request.
 
Fields inherited from interface com.cisco.jtapi.extensions.CiscoTerminal
APPLICATION, ASCII_ENCODING, DEVICESTATE_ACTIVE, DEVICESTATE_ALERTING, DEVICESTATE_HELD, DEVICESTATE_IDLE, DEVICESTATE_UNKNOWN, DEVICESTATE_WHISPER, DND_OPTION_CALL_REJECT, DND_OPTION_NONE, DND_OPTION_RINGER_OFF, IN_SERVICE, IP_ADDRESSING_MODE_IPV4, IP_ADDRESSING_MODE_IPV4_V6, IP_ADDRESSING_MODE_IPV6, IP_ADDRESSING_MODE_UNKNOWN, IP_ADDRESSING_MODE_UNKNOWN_ANATRED, NATIVE_LOGIN, NO_LOGIN, NO_ROLLOVER, NOT_APPLICABLE, OUT_OF_SERVICE, PHONE_USER, ROLLOVER_ANY_DN, ROLLOVER_SAME_DN, UCS2UNICODE_ENCODING, UNKNOWN_ENCODING, VISITOR_LOGIN
 
Method Summary
 int getRegistrationType()
          This API will return the registrationType with which the terminal has been registered.
 void register(java.net.InetAddress address, int port, CiscoMediaCapability[] capabilities, int registrationType, int[] algorithmIDs, java.net.InetAddress address_v6, int activeAddressingMode)
          The CiscoBaseMediaTerminal must be in the CiscoTerminal.UNREGISTERED state and its Provider must be in the Provider.IN_SERVICE state The successful effect of this method is to register the MediaTerminal.
 
Methods inherited from interface com.cisco.jtapi.extensions.CiscoTerminal
canConsultCallRollOver, canDirectTransferAcrossLines, canDirectTransferOnSameLine, canJoinAcrossLines, canJoinOnSameLine, canOutBoundCallRollOver, createSnapshot, directedPickup, getAltScript, getDeviceState, getDNDOption, getDNDStatus, getEMLoginUsername, getFilter, getIPAddressingMode, getIPV4Address, getIPV6Address, getLocale, getLoginType, getProtocol, getRegistrationState, getRollOverConfig, getRTPInputProperties, getRTPOutputProperties, getState, getSupportedEncoding, groupPickup, isBuiltInBridgeEnabled, isRegistered, isRestricted, otherPickup, pickup, sendData, sendData, setDNDStatus, setFilter, unPark
 
Methods inherited from interface javax.telephony.Terminal
addCallObserver, addObserver, getAddresses, getCallObservers, getCapabilities, getName, getObservers, getProvider, getTerminalCapabilities, getTerminalConnections, removeCallObserver, removeObserver
 
Methods inherited from interface com.cisco.jtapi.extensions.CiscoObjectContainer
getObject, setObject
 

Field Detail

NO_MEDIA_REGISTRATION

static final int NO_MEDIA_REGISTRATION
Applications that are not interested in media termination need to register with this type and pass in a null value for CiscoMediaCapability in the registration request. If registrationType is CiscoBaseMediaTerminal.NO_MEDIA_REGISTRATION, the application cannot terminate media and can use the CiscoBaseMediaTerminal for call routing.

See Also:
Constant Field Values

STATIC_MEDIA_REGISTRATION

static final int STATIC_MEDIA_REGISTRATION
Applications that are interested in static media termination need to register with this type and pass in the capabilities that the application supports in the registration request.

See Also:
Constant Field Values

DYNAMIC_MEDIA_REGISTRATION

static final int DYNAMIC_MEDIA_REGISTRATION
Applications that are interested in dynamic media termination need to register with this type and pass in the capabilities that the application supports in the registration request.

See Also:
Constant Field Values

STATIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT

static final int STATIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT
Applications that are interested in static media termination with support for SIP Trunk Early Offer need to register with this type and pass in the capabilities that the application supports in the registration request.

See Also:
Constant Field Values

DYNAMIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT

static final int DYNAMIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT
Applications that are interested in dynamic media termination need to register with this type and pass in the capabilities that the application supports in the registration request.

See Also:
Constant Field Values
Method Detail

register

void register(java.net.InetAddress address,
              int port,
              CiscoMediaCapability[] capabilities,
              int registrationType,
              int[] algorithmIDs,
              java.net.InetAddress address_v6,
              int activeAddressingMode)
              throws CiscoRegistrationException,
                     javax.telephony.PrivilegeViolationException
The CiscoBaseMediaTerminal must be in the CiscoTerminal.UNREGISTERED state and its Provider must be in the Provider.IN_SERVICE state The successful effect of this method is to register the MediaTerminal. activeAddressingMode indicates the application's IP Addressing Capabilities, If application specifies activeAddressingMode as CiscoTerminal.IP_ADDRESSING_MODE_IPv4, then it must also specify address If application specifies activeAddressingMode as CiscoTerminal.IP_ADDRESSING_MODE_IPv6, then it must also specify address_v6 If application specifies activeAddressingMode as CiscoTerminal.IP_ADDRESSING_MODE_IPv4_6, then it must also specify address and address_v6
Method Arguments
This method has seven arguments. The first argument specifies the internet address at which the RTP media stream for this Terminal will be terminated, the second indicates the UDP port at which RTP packets will be directed, the third argument indicates the type of RTP encodings that the application is willing to support for this Terminal and the fourth argument indicates SRTP algorithm that application supports, the fifth argument specifies the IPv6 address at which the RTP media stream for this terminal will be terminated if IPv6 is supported, the sixth argument specifies the addressing mode and the final argument specifies the registration type in which the application wishes to register this MediaTerminal. This method can be used only if application has TLS link established with CTIManager and if application has SRTP Enabled flag enabled in CM Admin pages for the user, otherwise PrivilegeViolationException is thrown.
Method Post-conditions
This method returns successfully when the MediaTerminal is registered.

Parameters:
address - the internet address for inbound IPv4 RTP streams on this terminal, it can be null depending on application's Addressing Mode
port - the UDP port for inbound RTP streams on this terminal
capabilities - the list of RTP encodings supported by this terminal
algorithmIDs - indicates SRTP algorithms that this CTIPort supports. AlgorithmIDs may only be one of CiscoMediaEncryptionAlgorithmType
address_v6 - the IPv6 internet address for inbound IPv6 RTP streams on this terminal, it can be null depending upon activeAddressingMode
activeAddressingMode - is IP Addressing mode in which application intends to register this CiscoMediaTerminal, activeAddressingMode can be: CiscoTerminal.IP_ADDRESSING_MODE_IPv4 or CiscoTerminal.IP_ADDRESSING_MODE_IPv6, or CiscoTerminal.IP_ADDRESSING_MODE_IPv4_v6
registrationType - is the type of registration in which application intends to register this CiscoMediaTerminal, registrationType can be: CiscoBaseMediaTerminal.NO_MEDIA_REGISTRATION or CiscoBaseMediaTerminal.DYNAMIC_MEDIA_REGISTRATION or CiscoBaseMediaTerminal.STATIC_MEDIA_REGISTRATION or CiscoBaseMediaTerminal.DYNAMIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT or CiscoBaseMediaTerminal.STATIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT
Throws:
CiscoRegistrationException
javax.telephony.PrivilegeViolationException
Since:
8.5
See Also:
CiscoMediaOpenIPPortEv

getRegistrationType

int getRegistrationType()
This API will return the registrationType with which the terminal has been registered. The registrationType returned will be one these values: CiscoBaseMediaTerminal.NO_MEDIA_REGISTRATION CiscoBaseMediaTerminal.DYNAMIC_MEDIA_REGISTRATION CiscoBaseMediaTerminal.STATIC_MEDIA_REGISTRATION CiscoBaseMediaTerminal.DYNAMIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT CiscoBaseMediaTerminal.STATIC_MEDIA_REGISTRATION_FOR_GET_PORT_SUPPORT

Returns:
int
Since:
8.5