I’m using groovy scripting in java. Here is how it operates: I’m creating in java BSFManager, then register some beans, then I receive groovy script from the input and pass it for execution to BSFManager instance. There is something I don’t understand. When I want to operate on class instances (beans) that I previously registered to BSFManager in my java code in my groovy script, I must use some special word ‘bsf’ to adress to BSFManager in my groovy script. E.g. bsf.lookupBean("mybeanname"). I didn’t found any definition of that special word “bsf”, but it seems to work. So what is the origin of that hidden bsf variable or where is it declared?
I’m using groovy scripting in java. Here is how it operates: I’m creating in
Share
BSF is short for Bean Scripting Framework, which is an Apache project for embedding scripting languages within Java applications.
The
bsfobject is created as part of that framework.From the manual:
The Apache Commons BSF manual