groovy-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Romain Manni-Bucau <>
Subject get bytecode from groovyclassloader?
Date Sun, 28 Oct 2018 17:58:01 GMT
Hi guys,

wonder if it would make sense to store the bytecode of the compiled scripts
in the groovyclassloader to be able to access it as any other classloader
(jar/file) using loader.getResource("class/path/with/full/Name.class")?

I know it can be done with a BytecodeProcessor but it is not that
convenient and the impl can be trivial
since groovy.lang.GroovyClassLoader.ClassCollector#createClass can also
populate some resource map as well. Don't think the subfolder emulation is
needed (ie getResource("class/path") can return null if the package does
not exist anywhere else).


Romain Manni-Bucau
@rmannibucau <> |  Blog
<> | Old Blog
<> | Github <> |
LinkedIn <> | Book

View raw message