importLib
Imports a Java class.
Overview:
API Reference
importLib()
importLib()var libLoader = importLib("library-name.jar");How It Works:
Example:
Last updated
Was this helpful?
Imports a Java class.
importLib()var libLoader = importLib("library-name.jar");Last updated
Was this helpful?
Was this helpful?
importLib(pathToJar)var RiveScriptLoader = importLib("rivescript-core-0.9.2.jar");
var RiveScriptClass = RiveScriptLoader.loadClass("com.rivescript.RiveScript");
// Create an instance of the RiveScript bot
var riveScript = RiveScriptClass.getConstructor().newInstance();
// Now you can call methods on riveScript