[asterisk-dev] AGI Function Control Stream File

Steven S. Critchfield critch at basesys.com
Wed Jul 15 13:40:21 CDT 2009


----- "Bryant Zimmerman" <BryantZ at zktech.com> wrote:
> After reviewing the ast_controlstreamfile code and 
> handles_controlstreamfile code. It looks to me that there are some
> inherent 
> limitations designed into the code.   I am not much of a c coder so I
> do 
> not think I can safely modify it at this time.
> 
> I would like to suggest two new functions that would allow for much
> cleaner 
> control from an agi programmers point of view. 
> stream file fastforward and stream file reverse. With these two
> functions 
> and the standard stream file I believe that an agi developer could
> make 
> almost any combination of playback decision. each would need to
> support a 
> digit return and endpos.  The only down side I can see to using this
> method 
> is a little more overhead on file open and close but I think the 
> flexibility merits it. 

Sounds like you want the functionality of the previous functions
re factored into standalone components. The first step is to see how
best to accomplish the refactoring, parts to separate and such. See
how once they are separated, how would the original maintain it's 
functionality. Then proceed to expose the new functionality to the
AGI programmer, or even the dialplan operator. 

In the plan as I outline here, there should be minimal new code as
the functionality already exists, but in a limited format. 

Next it allows testing to continue by whatever might already be
available as at the end of step one, the result to a AGI program or 
dialplan should be exactly the same as before.

Finally the new feature really will only be a way of mapping one
command to the other. Only real consideration would be how one
expects the arguments to be presented and result returned. 

While the deep insides may change, the current API shouldn't change.
If you can maintain current functionality, there should be no problem
for anyone to object. 

-- 
Steven Critchfield critch at basesys.com



More information about the asterisk-dev mailing list