Re: [Asterisk-java-users] How to get the source/hostname of an Event
Brought to you by:
srt
From: Murthy G. <mga...@nt...> - 2014-04-10 00:41:36
|
The following seems to work. Is this the correct way? ManagerConnection source= (ManagerConnection) event.getSource(); if (source == null) { logger.error("Cannot get source"); } else { logger.info("source:" + source.getHostname()); } ________________________________ From: Murthy Gandikota [mailto:mga...@nt...] Sent: Wednesday, April 09, 2014 4:27 PM To: ast...@li... Subject: [Asterisk-java-users] How to get the source/hostname of an Event I would be grateful if Yves or someone can answer my basic question. The Event object has a hostname attribute. But it is coming up as null. Using a proxy, for example: astman, will populate that field. How do they do that? Is there anyother way? I also am grateful if someone can post a clip about astman proxy. Thank you so much. Murthy |