This is usually done by just using a second class loader. Each class loader virtually lives in its own namespace. There's not need to do any renaming.
Apart from that I'd say "don't try this at home!" ;-) Eric On 20/11/2007, Hendrik Gani <[EMAIL PROTECTED]> wrote: > Dean Wampler wrote: > > I'm pretty sure the answer is no. I'm curious what "use case" you have > > in mind? > > > > dean > Thanks for the response Dean, > > Simply saying, basically I would like to be able to load jdk classes > from a different version of Java from the one I am using to run my > application. For example: I run my application using Java5 and in the > application I would like to load classes from Java1.4 JRE jar. I am not > trying to replace Java5 classes with Java1.4 ones, but instead, want to > use these two sets of classes independently, therefore in order to avoid > problems (such as name conflicts and security manager restrictions) I > have to rename the Java1.4 classes. > > Cheers, > > Hendrik > > > > > > > > > On Nov 20, 2007, at 9:19 PM, Hendrik Gani wrote: > > > >> Hi, > >> > >> I've been searching around and as I understand it, aspectj aims to > >> provide flexibility for developers to modify class behaviour by > >> allowing them to modify its fields, methods, constructors and even > >> the inheritance hierarchy. Therefore I guess it wouldn't support > >> arbitrary manipulation of a Java class (such as modifying its name), > >> however I'll give it a shot anyway by posting the question in this > >> mailing list. > >> So, does anyone know whether we could aspectj to modify the name of a > >> class? > >> > >> Thanks, > >> > >> Hendrik > >> > >> > >> _______________________________________________ > >> aspectj-users mailing list > >> [email protected] <mailto:[email protected]> > >> https://dev.eclipse.org/mailman/listinfo/aspectj-users > > > > Dean Wampler, Ph.D. > > dean at objectmentor.com > > http://www.objectmentor.com > > See also: > > http://www.aspectprogramming.com AOP advocacy site > > http://aquarium.rubyforge.org AOP for Ruby > > http://www.contract4j.org Design by Contract for Java5 > > > > > > > > ------------------------------------------------------------------------ > > > > _______________________________________________ > > aspectj-users mailing list > > [email protected] > > https://dev.eclipse.org/mailman/listinfo/aspectj-users > > > _______________________________________________ > aspectj-users mailing list > [email protected] > https://dev.eclipse.org/mailman/listinfo/aspectj-users > -- Eric Bodden Sable Research Group McGill University, Montréal, Canada _______________________________________________ aspectj-users mailing list [email protected] https://dev.eclipse.org/mailman/listinfo/aspectj-users
