Type safing an Enumeration [message #160480] |
Mon, 13 February 2006 08:22 |
Eclipse User |
|
|
|
Originally posted by: ns_dkerber.ns_WarrenRogersAssociates.com
This is more of a Java question than it an eclipse, but I'm seeing it in
a Dynamic Web project in eclipse, so I thought I'd start here first. If
there's a better place to ask it, please let me know!
I have ported my Dynamic Web Project from 1.4 to 1.5, and have corrected
90% of the resulting type safety warnings, but I can't figure out how to
handle ones which come from HttpServletRequest.getParameterNames() and
HttpServletRequest.getParameterValues() calls.
According to the docs, these calls return an Enumeration of Strings, so
I use a statement like:
Enumeration<String> parms = request.getParameterNames();
However, I still get the following warning:
Type safety: The expression of type Enumeration needs unchecked
conversion to conform to Enumeration<String>
Is there any way to stop this warning, or do I just have to turn it off
or ignore it?
Thanks!
--
Remove the ns_ from if replying by e-mail (but keep posts in the
newsgroups if possible).
|
|
|
Powered by
FUDForum. Page generated in 0.03461 seconds