0

我正在使用 JTapi 来控制 Cisco 电话。我熟悉连接、终端、呼叫等的各种状态。但是,我注意到没有类似于回铃的状态。有没有办法判断手机状态是否为“回铃”?据我了解,当被叫电话处于“警报”状态时,主叫电话应该具有“回铃”状态。任何帮助将不胜感激。

顺便说一句,这就是我到目前为止所拥有的。不确定是否正确。

int counter = 0;

CallControlCall abc = (CallControlCall)provider.getAddress(phone).getConnections()[0].getCall();

for(Connection conn: abc.getConnections()){
    if(abc.getCallingAddress().equals(conn.getAddress()) && conn.getState() == Connection.CONNECTED)
                counter++;
    if(abc.getCalledAddress().equals(conn.getAddress()) && conn.getState() == Connection.ALERTING)
                counter++;
        }
if(counter == 2)
    System.out.println("The state of the calling phone is ringback!");
4

1 回答 1

0

你已经看过 CallControl 包了吗?CallControlConnection 有一个状态 NETWORK_ALERTING。如果这得到 CISCO 实施的支持,那么这应该是您正在寻找的。

有关详细信息,请参阅 CallControl package_summary

于 2016-02-03T08:04:26.273 回答