[infinispan-dev] [Pull Request] Modular Classloading Compatibility
Manik Surtani
manik at jboss.org
Wed May 18 11:36:48 EDT 2011
On 4 May 2011, at 14:55, Dan Berindei wrote:
>
> If V is Set<MyObject> then Set<MyObject>.class.getClassLoader() will
> give you the system classloader, which in most cases won't be able the
> MyObject class. It may not even be a Set<MyObject> of course, it could
> be just Set<?>.
>
> We could have a "shortcut" so the users can pass in a class instead of
> a classloader to avoid writing ".getClassLoader()", but we shouldn't
> require any relation between the class passed in and the class of the
> return value.
Very good point.
--
Manik Surtani
manik at jboss.org
twitter.com/maniksurtani
Lead, Infinispan
http://www.infinispan.org
More information about the infinispan-dev
mailing list