Bug 48870 - avoid parallel arrays of base types
avoid parallel arrays of base types
Product: Tomcat 7
Classification: Unclassified
Component: Catalina
All All
: P4 enhancement (vote)
: ---
Assigned To: Tomcat Developers Mailing List
Depends on:
  Show dependency tree
Reported: 2010-03-08 06:55 UTC by Ralf Hauser
Modified: 2011-02-18 16:48 UTC (History)
0 users

patch_parallelArrays.txt (11.30 KB, text/plain)
2010-03-08 06:55 UTC, Ralf Hauser

Note You need to log in before you can comment on or make changes to this bug.
Description Ralf Hauser 2010-03-08 06:55:57 UTC
Created attachment 25103 [details]

having kind of 'synchronized' arrays, i.e. one of Strings and another one of Integers appears to be a questionable programming pattern to me.

Pls find attached a hopefully more OO approach

see also bug 48158
Comment 1 Ralf Hauser 2010-03-08 06:58:52 UTC
oops, the related RFE should have been Bug 48863
Comment 2 Christopher Schultz 2010-11-09 17:45:05 UTC

Why did you submit a patch with deprecated items in it? Instead of documenting the items to be deprecated, just go all the way with the enum.

Also, I'm not sure that BootLocation necessarily needs to implement CharSequence. I think it would be cleaner for BootLocation to simply contain a String (location) and enum type.

I don't happen to like the name BootLocation but that's just a matter of taste. Maybe RepositoryLocation?
Comment 3 Mark Thomas 2011-02-18 16:48:12 UTC
Fixed in trunk and will be in 7.0.9 onwards. Since I agree with Chris's views, the patch applied was along those lines.