[asterisk-dev] [asterisk-commits] murf: trunk r89272 - /trunk/main/pbx.c

Kevin P. Fleming kpfleming at digium.com
Fri Nov 16 09:34:35 CST 2007


SVN commits to the Asterisk project wrote:
> Author: murf
> Date: Wed Nov 14 12:05:50 2007
> New Revision: 89272
> 
> URL: http://svn.digium.com/view/asterisk?view=rev&rev=89272
> Log:
> Rescaled the weights of the patterns to give something more independent of pattern length; and make . less likely to win. Question: which should win for 14102241145-- _1xxxxxxx.   or  _XXXXXXXXXXX  -- right now, the pure X pattern will win.

That's a tough question to answer; in general, more specific patterns
should be given higher scores, so the pattern starting with '1' is
better. However, it is shorter and ends with '.', where the longer
pattern is expecting a specific number of digits... so it is better.

In my opinion the presence of more-specific characters should carry more
weight than pattern length, but not so much weight that "_91." has a
higher score than "_XXXXXX".

We really need to get some community feedback on this... how about
taking a poll and posing the question with 5 or 6 combinations of A/B
patterns and asking (in each case) which one should win, then tabulating
the results?

-- 
Kevin P. Fleming
Director of Software Technologies
Digium, Inc. - "The Genuine Asterisk Experience" (TM)



More information about the asterisk-dev mailing list