jakarta-bsf-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jiger Patel" <jiger_...@hotmail.com>
Subject Dynamic Classpaths with BSF
Date Thu, 30 Jan 2003 12:47:56 GMT
Hi All,
        I am new to the List & BSF so forgive my ignorance. I searched the 
archives & google but did not find any tip on my problem so I hope I will 
get some answer here.
My Problem is this:
I am creating a scripting app where the classes are not set in the classpath 
since they are loaded by the parent app from its lib directory. Now I want 
to somehow set the classpath/classloader such that all the classes/jars that 
I add to BSFManager can be resolved by the various scripting engines. I 
tried setting this using setClassPath & setClassLoader but yet, 
jython/beanshell etc scripting engines cannot find the package 
org.apache.bsh which is there in the lib directory. On investigating the 
source code. It seems the BSFManager's classpath & classloaders are not used 
by the Scripting Engines in anyway to facilitate such dynamic classpaths.
Now I have this requirement very urgent & need to load jars for a particular 
designated directory at runtime when I create BSFManager instance. Is there 
some way to force engines to add the mentioned classes. I don't want to mess 
with ClassLoaders so setting classpath is what I am looking at.

Any idea how this can be achieved.

Thanks in Advance,
Jiger.





_________________________________________________________________
Add photos to your e-mail with MSN 8. Get 2 months FREE*. 
http://join.msn.com/?page=features/featuredemail


Mime
View raw message