cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
346
Views
0
Helpful
3
Replies

jtapi/java get phone description

Davide Fiumi
Level 1
Level 1

HI,

I developed a jtpai application that view a list of all phones(MAC Address) registered on CallManager.

How can I view the phones description?

Regards.

3 Replies 3

msabir
Level 4
Level 4

The following is the Java code to view phone description. It calls AXL web service and gets the list of phone and loops through them to find description of each phone:

// Call the web service and get results

SelectCmDeviceResult results = proxy.selectCmDevice(stateInfo, cmSelectionCriteria);

Object cmNodes[] = results.getCmNodes();

Object devices[] = cmNodes[0].getCmDevices();

for (int i = 0; i < devices.length; i++) {

CmDevice cmDevice = (CmDevice) devices[i];

String description=cmDevice.getDescription();

}

My problem is to understand how i can call the web service and get results from JAVA.

Can you send me an example code?

your code works only with callManager 5?

with 4?

It works with both CCM 4 and 5 (possibly with 6 as well). If you use Eclipse 3.3, it will create all Java classes for you from WSDL file. All you have to do, is to call those classes, like I showed in the code sample above. Once you have stub classes created, my code above will start to make sense. I am thinking to write a quick tech note on how to use AXL in CCM using Eclipse and WSDL.

NetBeans 5.5.1 or 6.0 beta 1, can also do the same but I am more familiar with Eclipse.