David Durham, Jr. wrote:
On Thu, Mar 6, 2008 at 2:42 PM, Brian Pontarelli <[EMAIL PROTECTED]> wrote:
You can't put things into Maps that have wildcards. The compiler
complains because Object really isn't '?'. Although most language
pragmatist would tell you it is. But the language zealots say otherwise,
and those are the folks who wrote generics. :)
The general rule is that you don't use wildcard if you need to 'get'
and 'put'. You use extends when you only 'get' and super when you
only 'put'.
Yeah, I didn't want to toss in super because it can really rattle
people's brains if they don't know what it means. :)
-bp
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]