<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <!-- /home/espenr/tmp/qt-3.3.6-espenr-14571/qt-x11-free-3.3.6/extensions/activeqt/container/qaxscript.cpp:360 --> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> <title>QAxScriptEngine Class</title> <style type="text/css"><!-- fn { margin-left: 1cm; text-indent: -1cm; } a:link { color: #004faf; text-decoration: none } a:visited { color: #672967; text-decoration: none } body { background: #ffffff; color: black; } --></style> </head> <body> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr bgcolor="#E5E5E5"> <td valign=center> <a href="index.html"> <font color="#004faf">Home</font></a> | <a href="classes.html"> <font color="#004faf">All Classes</font></a> | <a href="mainclasses.html"> <font color="#004faf">Main Classes</font></a> | <a href="annotated.html"> <font color="#004faf">Annotated</font></a> | <a href="groups.html"> <font color="#004faf">Grouped Classes</font></a> | <a href="functions.html"> <font color="#004faf">Functions</font></a> </td> <td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><h1 align=center>QAxScriptEngine Class Reference<br><small>[<a href="qaxcontainer.html">QAxContainer module</a>]</small></h1> <p>The QAxScriptEngine class provides a wrapper around a script engine. <a href="#details">More...</a> <p>This class is part of the <b>Qt ActiveQt Extension</b>. <p><tt>#include <<a href="qaxscript-h.html">qaxscript.h</a>></tt> <p>Inherits <a href="qaxobject.html">QAxObject</a>. <p><a href="qaxscriptengine-members.html">List of all member functions.</a> <h2>Public Members</h2> <ul> <li class=fn>enum <a href="#State-enum"><b>State</b></a> { Uninitialized = 0, Initialized = 5, Started = 1, Connected = 2, Disconnected = 3, Closed = 4 }</li> <li class=fn><a href="#QAxScriptEngine"><b>QAxScriptEngine</b></a> ( const QString & language, QAxScript * script )</li> <li class=fn><a href="#~QAxScriptEngine"><b>~QAxScriptEngine</b></a> ()</li> <li class=fn>bool <a href="#isValid"><b>isValid</b></a> () const</li> <li class=fn>bool <a href="#hasIntrospection"><b>hasIntrospection</b></a> () const</li> <li class=fn>QString <a href="#scriptLanguage"><b>scriptLanguage</b></a> () const</li> <li class=fn>State <a href="#state"><b>state</b></a> () const</li> <li class=fn>void <a href="#setState"><b>setState</b></a> ( State st )</li> <li class=fn>void <a href="#addItem"><b>addItem</b></a> ( const QString & name )</li> <li class=fn>long <a href="#queryInterface"><b>queryInterface</b></a> ( const QUuid & uuid, void ** iface ) const</li> </ul> <hr><a name="details"></a><h2>Detailed Description</h2> <p> This class is defined in the <b>Qt <a href="activeqt.html#ActiveQt">ActiveQt</a> Extension</b>, which can be found in the <tt>qt/extensions</tt> directory. It is not included in the main Qt API. <p> The QAxScriptEngine class provides a wrapper around a script engine. <p> Every instance of the QAxScriptEngine class represents an interpreter for script code in a particular scripting language. The class is usually not used directly. The <a href="qaxscript.html">QAxScript</a> and <a href="qaxscriptmanager.html">QAxScriptManager</a> classes provide convenient functions to handle and call script code. <p> Direct access to the script engine is provided through <a href="#queryInterface">queryInterface</a>(). <p> <b>Warning:</b> This class is not available with the bcc5.5 and MingW compilers. <hr><h2>Member Type Documentation</h2> <h3 class=fn><a name="State-enum"></a>QAxScriptEngine::State</h3> <p> The State enumeration defines the different states a script engine can be in. <ul> <li><tt>QAxScriptEngine::Uninitialized</tt> - The script has been created, but not yet initialized <li><tt>QAxScriptEngine::Initialized</tt> - The script has been initialized, but is not running <li><tt>QAxScriptEngine::Started</tt> - The script can execute code, but does not yet handle events <li><tt>QAxScriptEngine::Connected</tt> - The script can execute code and is connected so that it can handle events <li><tt>QAxScriptEngine::Disconnected</tt> - The script is loaded, but is not connected to event sources <li><tt>QAxScriptEngine::Closed</tt> - The script has been closed. </ul> <hr><h2>Member Function Documentation</h2> <h3 class=fn><a name="QAxScriptEngine"></a>QAxScriptEngine::QAxScriptEngine ( const <a href="qstring.html">QString</a> & language, <a href="qaxscript.html">QAxScript</a> * script ) </h3> Constructs a QAxScriptEngine object interpreting script code in <em>language</em> provided by the code in <em>script</em>. This is usually done by the <a href="qaxscript.html">QAxScript</a> class when <a href="qaxscript.html#load">loading a script</a>. <p> Instances of QAxScriptEngine should always have both a language and a script. <h3 class=fn><a name="~QAxScriptEngine"></a>QAxScriptEngine::~QAxScriptEngine () </h3> Destroys the QAxScriptEngine object, releasing all allocated resources. <h3 class=fn>void <a name="addItem"></a>QAxScriptEngine::addItem ( const <a href="qstring.html">QString</a> & name ) </h3> Registers an item with the script engine. Script code can refer to this item using <em>name</em>. <h3 class=fn>bool <a name="hasIntrospection"></a>QAxScriptEngine::hasIntrospection () const </h3> Returns TRUE if the script engine supports introspection; otherwise returns FALSE. <h3 class=fn>bool <a name="isValid"></a>QAxScriptEngine::isValid () const </h3> <p> Returns TRUE if the script engine has been initialized correctly; otherwise returns FALSE. <h3 class=fn>long <a name="queryInterface"></a>QAxScriptEngine::queryInterface ( const <a href="quuid.html">QUuid</a> & uuid, void ** iface ) const </h3> Requests the interface <em>uuid</em> from the script engine object and sets the value of <em>iface</em> to the provided interface, or to 0 if the requested interface could not be provided. <p> Returns the result of the QueryInterface implementation of the COM object. <h3 class=fn><a href="qstring.html">QString</a> <a name="scriptLanguage"></a>QAxScriptEngine::scriptLanguage () const </h3> Returns the scripting language, for example "VBScript", or "JScript". <h3 class=fn>void <a name="setState"></a>QAxScriptEngine::setState ( <a href="qaxscriptengine.html#State-enum">State</a> st ) </h3> Sets the state of the script engine to <em>st</em>. Calling this function is usually not necessary. <h3 class=fn><a href="qaxscriptengine.html#State-enum">State</a> <a name="state"></a>QAxScriptEngine::state () const </h3> Returns the state of the script engine. <!-- eof --> <hr><p> This file is part of the <a href="index.html">Qt toolkit</a>. Copyright © 1995-2005 <a href="http://www.trolltech.com/">Trolltech</a>. All Rights Reserved.<p><address><hr><div align=center> <table width=100% cellspacing=0 border=0><tr> <td>Copyright © 2005 <a href="troll.html">Trolltech</a><td align=center><a href="trademarks.html">Trademarks</a> <td align=right><div align=right>Qt 3.3.6</div> </table></div></address></body> </html>