anish
anish

Reputation: 7412

GroovyClassLoader using method recompile removeClassCacheEntry

How can i use these methods

protected Class     recompile(URL source, String className, Class oldClass)

(Re)Compiles the given source.

protected void  removeClassCacheEntry(String name)

removes a class from the class cache.

in my program using GroovyClassLoader

Upvotes: 0

Views: 311

Answers (1)

blackdrag
blackdrag

Reputation: 6508

These methods are protected, becaue you are not really supposed to call them directly and only if you need to extend the GroovyClassLoader (GCL) with special logic. GCL does also handle only simple cases of recompilation, it cannot handle recompilation dependencies. You are supposed to use GroovyScriptEngine for these kind of things.

Upvotes: 2

Related Questions