I would have some interesting uses for this
package; however, I would need to use the
generated classes without having to save them
to disk and then be loaded via the normal
classloader. Do you think this is possible?
Perhaps via a custom classloader?
-steve
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Using a custom classloader is exactly the right idea. Notice that the BCClass object has a method called getBytes() that returns a byte[] consisting of the class definition. This method is there for the sole purpose of loading a newly generated/modified class into a custom class loader.
Good luck.
-- Abe
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I would have some interesting uses for this
package; however, I would need to use the
generated classes without having to save them
to disk and then be loaded via the normal
classloader. Do you think this is possible?
Perhaps via a custom classloader?
-steve
Steve --
Using a custom classloader is exactly the right idea. Notice that the BCClass object has a method called getBytes() that returns a byte[] consisting of the class definition. This method is there for the sole purpose of loading a newly generated/modified class into a custom class loader.
Good luck.
-- Abe