Quote Originally Posted by TheCPUWizard
While casts were definately required with 1.x containers it was always recommended to create a type safe wrapper class so that all of the casts were localized to that class (try saying that three times fast!) and that casts were not required outside the typesafe container.
Writing a wrapper doesn't sort out the basic underlying issue of the type system. Isn't it? Rather than patch-work that needed a more basic fix in the framework. Limiting the scope of the problem doesn't mean that the problem doesn't exist. As for lassunde's question, he/she can use casting as much as wanted and localize that code to his own API layer. Is that justified? Moreover, there are efficiency issues related to that.

Also, when I said non-generic containers - that implied those off the pre-2.0 releases that included generics (1.x or whatever). Isn't it?