on 4/19/00 8:38 AM, Jeffrey D.Brekke <[EMAIL PROTECTED]> wrote:

> But if we added a string and used getString("ERRORLEVEL") it would not work.
> ParameterParser was converting the names to lowercase and stripping spaces
> when the object was initialized.  But when a value was added via an add()
> method, the name was not converted ( via ParameterParser.convert(String) ).
> But some retrieval methods where converting the name before retrieval.  So in
> some cases this was working and others it was not.  I've included a patch
> where nothing is converted via the convert() method, but am wondering if there
> was a reason this was in here.  We don't have to 'not convert' any thing, but
> then we'd have to be consistent when adding to the parameters to convert the
> name also and document this side-effect.  Anyway here's the patch which
> removes the stripping and lower-casing of the names.  I left the
> ParameterParser.convert(String) method alone, but it is no longer used
> internally by ParameterParser.

-1

I added that convert method because I felt that the name= portion of a
name=value pair should be case insensitive. By making it lowercase and then
checking for that lowercase that resolves the issue. It sounds like I (or
someone else) forgot to put a convert() in there somewhere. The reason I
think it should be case insensitive is that it is bad programming practice
to depend on case sensitivity of variable names like that because it would
be easy to spend hours tracking down that as a problem. I don't want to
encourage that.

I just checked in the one line fix to the add() method.

-jon

--
Scarab -
      Java Servlet Based - Open Source
         Bug/Issue Tracking System
        <http://scarab.tigris.org/>




------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to