[Asterisk-Dev] Common app option processing...

Kevin P. Fleming kpfleming at starnetworks.us
Mon Nov 1 16:24:52 MST 2004


Michael Loftis wrote:
> OK after digging around in various different * apps, it's pretty clear 
> we need a COMMON option processing call and/or lib.  It's pretty nuts 
> that ever app implements it's own option processing fromt eh ground up, 
> and there is no consistency.

I fully agree. The code duplication is wasteful, plus it makes for 
inconsistent option parsing between apps. I have an application where I 
need to be able to put '|' characters into application arguments, which 
currently can't be done because it's the argument separator.

An option parsing function that could take the entire "data" string and 
bust it up _properly_ into arguments would be very nice to have, 
especially if it could support quoting and special character escaping.

Whether it would get used or not is the open question... if you 
implement it, and convert a major app over to it without problems, then 
I'd suspect everyone else would be happy to use it. I could be wrong 
though :-)



More information about the asterisk-dev mailing list