bsh.commands.importCommands.bsh Maven / Gradle / Ivy
The newest version!
/**
Import scripted or compiled BeanShell commands in the following package
in the classpath. You may use either "/" path or "." package notation.
e.g.
// equivalent
importCommands("/bsh/commands")
importCommands("bsh.commands")
When searching for a command each path will be checked for first, a file
named 'command'.bsh and second a class file named 'command'.class.
You may add to the BeanShell classpath using the addClassPath() or
setClassPath() commands and then import them as usual.
addClassPath("mycommands.jar");
importCommands("/mypackage/commands");
If a relative path style specifier is used then it is made into an absolute
path by prepending "/". Later imports take precedence over earlier ones.
Imported commands are scoped just like imported clases.
@method void importCommands( resource path | package name )
*/
bsh.help.importCommands = "usage: importCommands( string )";
importCommands( path )
{
this.caller.namespace.importCommands( path );
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy