Unidata/IDV — pull request #32 by tommyjasmin (2013-03-22 14:48:49+00:00)
Title: Better validation for numeric ranges

Hi guys - these mods came about when someone noticed you cannot use lowercase "e" when using scientific notation. Both upper and lowercase should be allowed. See section titled "E notation" from the Wikipedia page:

http://en.wikipedia.org/wiki/Scientific_notation

But worse, the Change Range UI was not parsing input correctly, due to behavior of the Misc.parseNumber() method, which would take the first valid double and drop any characters after that. As a result, something like:

1.2crud

would get parsed as 1.2, but:

1.2e-8

would also get parsed as 1.2, instead of the correct scientific notation.

The mods I made will IMO correctly flag 1.2crud as invalid, and accept all correct forms of floating point numbers.