evaluate

abstract fun evaluate(source: String, name: String = "<script>"): String?

Runs source and returns its result as text, or null when the result is undefined or null. name labels the script in error messages.

Throws

when the script throws, does not parse, or runs past the engine's limits.