Re: [Asterisk-java-devel] FW: [Asterisk-java-users] Setting the accountcode when firing anoriginate
Brought to you by:
srt
From: Stefan R. <ste...@re...> - 2008-06-04 18:54:57
|
Hi Martin, On the one hand opening up these two methods somehow mixes two different layers of abraction (manager and live) on the other hand achieving full flexibility with additional methods would be hard and would result in a number of new methods that hare hard to use due to their large signature. So I would go the pragmatic way and open them up. Any other ideas on this? =Stefan Martin Smith wrote: > Hello folks, > > Do we want to go down the "proliferation of arguments" way with the Live > API? Richard here (see forwarded message) needs to set more fields on > the originate action... > > Would it be better to just open up these two as public or protected? > - private AsteriskChannel originate(OriginateAction originateAction) > - private void originateAsync(OriginateAction originateAction, > OriginateCallback cb) > > Or would we prefer I add more methods/arguments? > > > Martin Smith, Systems Developer > ma...@be... > Bureau of Economic and Business Research > University of Florida > (352) 392-0171 Ext. 221 > > > > ------------------------------------------------------------------------ > *From:* ast...@li... > [mailto:ast...@li...] *On Behalf Of > *Richard Hamnett > *Sent:* Tuesday, June 03, 2008 5:17 PM > *To:* ast...@li... > *Subject:* Re: [Asterisk-java-users] Setting the accountcode when firing > anoriginateToExtensionAsync > > Hi Martin > > > I tried the combination of "CDR(accountcode)" "account" "Account" > "accountcode" and nothing seems to work unfortunately. > > > > > Rick > > > > > > > Hi Richard, > > Have you tried using "Account" instead of "CDR(accountcode)"? > > The spec for the Manager API's originate action calls it "Account" -- > http://www.voip-info.org/wiki/view/Asterisk+Manager+API+Action+Originate > ... > > If that doesn't work, it would be trivial for us to add it to the live > API as a method argument, so you can call it more directly. > > Let us know :) > > > Martin Smith, Systems Developer > martins@be... > Bureau of Economic and Business Research > University of Florida > (352) 392-0171 Ext. 221 > > > > > ________________________________ > > From: asterisk-java-users-bounces@li... > [mailto:asterisk-java-users-bounces@li...] On Behalf Of > Richard Hamnett > Sent: Tuesday, June 03, 2008 4:38 PM > To: asterisk-java-users@li... > Subject: [Asterisk-java-users] Setting the accountcode when > firing anoriginateToExtensionAsync > > > I was wondering if someone can help me, i'm using > originateToExtensionAsync to create a call but I cannot figure out a way > to set the account code within the method > > I tried something along the lines of: > > > Map<String, String> m = new HashMap<String, String>(); > > m.put("CDR(accountcode)", accountCode); > > serverBean.getServer().originateToExtensionAsync("Local/3"+ > exten + "@cmyContext/n", "myContext", companyNumber, 1, 15000L, new > CallerId(companyName, companyNumber), m, callbackBean); > > > > Can anyone kindly suggest how to do so? > > Thanks, > > Richard > > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > > > ------------------------------------------------------------------------ > > _______________________________________________ > Asterisk-java-devel mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-devel -- reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... WWW: http://www.reucon.com Steuernummern 215/5140/1791 USt-IdNr. DE220701760 |