KJS-API
kjsinterpreter.h
Go to the documentation of this file.
A class representing a global object of an execution environment.
Definition kjsobject.h:281
KJSInterpreter()
Constructs an interpreter with a default global object.
Definition kjsinterpreter.cpp:88
KJSResult evaluate(const QString &sourceURL, int startingLineNumber, const QString &code, KJSObject *thisValue=0)
Evaluates a piece of code with a "this" set to (optionally set) value.
Definition kjsinterpreter.cpp:163
KJSContext * globalContext()
Returns a handle to the global execution context.
Definition kjsinterpreter.cpp:148
KJSObject globalObject()
Returns the object that is used as the global object during all script execution performed by this in...
Definition kjsinterpreter.cpp:156
KJSInterpreter & operator=(const KJSInterpreter &other)
Assign another interpreter instance to this object.
Definition kjsinterpreter.cpp:121
const KJSContext * globalContext() const
This is an overloaded member function, provided for convenience. It differs from the above function o...
static bool normalizeCode(const QString &codeIn, QString *codeOut, int *errLine=0, QString *errMsg=0)
Reformat the given script code to an easy to read format with only one statement per line.
Definition kjsinterpreter.cpp:203
bool isException() const
Returns true if the script evaluation has caused an exception.
Definition kjsinterpreter.cpp:73
KJSResult & operator=(const KJSResult &)
Assigns the properties of another result object to this one.
Definition kjsinterpreter.cpp:57
QString errorMessage() const
Returns the error message if this is an exception result.
Definition kjsinterpreter.cpp:78
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Tue Mar 25 2025 00:00:00 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2025 The KDE developers.
Generated on Tue Mar 25 2025 00:00:00 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.