Qt:Документация 4.3.2/qaxscriptengine

Материал из Wiki.crossplatform.ru

Перейти к: навигация, поиск
40px Внимание: Актуальная версия перевода документации находится здесь

__NOTOC__

Image:qt-logo.png

Главная · Все классы · Основные классы · Классы по группам · Модули · Функции

Image:trolltech-logo.png

Содержание

[править] QAxScriptEngine Class Reference
[ QAxContainer module]

The QAxScriptEngine class provides a wrapper around a script engine. Далее...

 #include <QAxScriptEngine>

Inherits QAxObject.

[править] Открытые типы

  • enum State { Uninitialized, Initialized, Started, Connected, Disconnected, Closed }

[править] Открытые функции

  • 1 public function inherited from QAxObject
  • 29 открытых функций, унаследованных от QObject
  • 19 public functions inherited from QAxBase

[править] Дополнительные унаследованные члены

  • 1 свойство, унаследованное от QObject
  • 1 property inherited from QAxBase
  • 1 открытый слот, унаследованный от QObject
  • 1 сигнал, унаследованный от QObject
  • 3 signals inherited from QAxBase
  • 5 статических открытых членов, унаследованных от QObject
  • 7 защищенных функций, унаследованных от QObject
  • 5 protected functions inherited from QAxBase

[править] Подробное описание

The QAxScriptEngine class provides a wrapper around a script engine.

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 QAxScript and QAxScriptManager classes provide convenient functions to handle and call script code.

Direct access to the script engine is provided through queryInterface().

Warning: This class is not available with the bcc5.5 and MingW compilers.

See also QAxScript, QAxScriptManager, QAxBase, and ActiveQt Framework.


[править] Описание типов

[править]
enum QAxScriptEngine::State

The State enumeration defines the different states a script engine can be in.


Константа Значение Описание
QAxScriptEngine::Uninitialized 0 The script has been created, but not yet initialized
QAxScriptEngine::Initialized 5 The script has been initialized, but is not running
QAxScriptEngine::Started 1 The script can execute code, but does not yet handle events
QAxScriptEngine::Connected 2 The script can execute code and is connected so that it can handle events
QAxScriptEngine::Disconnected 3 The script is loaded, but is not connected to event sources
QAxScriptEngine::Closed 4 The script has been closed.

[править] Описание функций-членов

[править]
QAxScriptEngine::QAxScriptEngine ( const QString & language, QAxScript * script )

Constructs a QAxScriptEngine object interpreting script code in language provided by the code in script. This is usually done by the QAxScript class when loading a script.

Instances of QAxScriptEngine should always have both a language and a script.

[править]
QAxScriptEngine::~QAxScriptEngine ()

Destroys the QAxScriptEngine object, releasing all allocated resources.

[править]
void QAxScriptEngine::addItem ( const QString & name )

Registers an item with the script engine. Script code can refer to this item using name.

[править]
bool QAxScriptEngine::hasIntrospection () const

Returns true if the script engine supports introspection; otherwise returns false.

[править]
bool QAxScriptEngine::isValid () const

Returns true if the script engine has been initialized correctly; otherwise returns false.

[править]
long QAxScriptEngine::queryInterface ( const QUuid & uuid, void ** iface ) const

Requests the interface uuid from the script engine object and sets the value of iface to the provided interface, or to 0 if the requested interface could not be provided.

Returns the result of the QueryInterface implementation of the COM object.

[править]
QString QAxScriptEngine::scriptLanguage () const

Returns the scripting language, for example "VBScript", or "JScript".

[править]
void QAxScriptEngine::setState ( State st )

Sets the state of the script engine to st. Calling this function is usually not necessary.

Смотрите также state().

[править]
State QAxScriptEngine::state () const

Returns the state of the script engine.

See also setState().



Copyright © 2007 Trolltech Trademarks
Qt 4.3.2