Re: [Asterisk-java-users] getResponse. Success vs Follows.
Brought to you by:
srt
From: Stefan R. <sr...@re...> - 2006-01-25 10:34:12
|
Hi, try it this way: // connect to Asterisk and log in managerConnection.login(); response = managerConnection.sendAction( new CommandAction("sip show peers")); if (response instanceof CommandResponse) { CommandResponse commandResponse = (CommandResponse) response; Iterator lineIterator = commandResponse.getResult().iterator(); while (lineIterator.hasNext()) { System.out.println(lineIterator.next()); } } // and finally log off and disconnect managerConnection.logoff(); "Follows" just indicates that the result is a CommandResponse. This is due to the way Asterisk handles the CommandAction; it has no further meaning. =Stefan Jan du Toit schrieb: > Hi. > > When executing manager actions such as originate, hangup, etc one will > either get "Success" or "Error" when calling getResponse() on the > manager response that your action returns. > > But on some other actions one will get "Follows". Usually in this case > even if I cast to the correct type of response all I get out of the > attributes is follows, the unique id the rest is null > This is not enough information. > > What does "Follows" mean? > > Thanks. > > > > ------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. Do you grep through log > files > for problems? Stop! Download the new AJAX search engine that makes > searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642 > _______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users |