How to cannonicate numbers in international form
mail at joachim-breitner.de
Thu Jul 17 22:00:01 CEST 2008
Am Donnerstag, den 17.07.2008, 16:30 -0300 schrieb Werner Almesberger:
> How about making it configurable, with rules depending on prefix and
> "local zone(s)". E.g.,
> * -> last six digits must match
> +4121* -> last seven digits must match (i.e., landline, Vaud, Switzerland)
> +5411* -> last eight digits must match (i.e., landline, Buenos Aires)
> AR && 011* -> as above
> BUE && 15* -> last eight digits must match (i.e., cellular, Buenos Aires)
> (In fact, the last rule could just be "BUE", since all numbers here are
> unique in their last eight digits.)
I assume you meant „configurable by the programmer or maybe
distributor“, and not by the regular user?
> In most cases, just a simple "n last digits match" test would be
> sufficient. That's what all the usual phones do anyway, and false
> matches are very rare. But hey, we can be more sophisticated :-)
I’ll think I’ll start working on the 7 last digit match first, and we’ll
see if there are users that need more...
> By the way, I don't think requiring people to enter canonical numbers
> is a good idea. When you travel, you often enough get numbers that
> work if you dial them locally "as is", but you may not necessarily
> have a good enough understanding of the local numbering plan to turn
> them into fully qualified numbers.
Right, that’s my opinion as well.
e-Mail: mail at joachim-breitner.de
Jabber-ID: nomeata at joachim-breitner.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 197 bytes
Desc: Dies ist ein digital signierter Nachrichtenteil
Url : http://lists.openmoko.org/pipermail/devel/attachments/20080717/b9699f39/attachment.pgp
More information about the devel