• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdelibs API Reference
  • KDE Home
  • Contact Us
 

Kross

  • Kross
  • Script
Public Slots | Public Member Functions | List of all members
Kross::Script Class Referenceabstract

#include <script.h>

Inheritance diagram for Kross::Script:
Inheritance graph
[legend]

Public Slots

Action * action () const
 
virtual QVariant callFunction (const QString &name, const QVariantList &args=QVariantList())=0
 
virtual QVariant evaluate (const QByteArray &code)=0
 
virtual void execute ()=0
 
virtual QStringList functionNames ()=0
 
Interpreter * interpreter () const
 

Public Member Functions

 Script (Interpreter *interpreter, Action *action)
 
virtual ~Script ()
 
- Public Member Functions inherited from Kross::ErrorInterface
 ErrorInterface ()
 
void clearError ()
 
long errorLineNo () const
 
const QString errorMessage () const
 
const QString errorTrace () const
 
bool hadError () const
 
void setError (const QString &errormessage, const QString &tracemessage=QString(), long lineno=-1)
 
void setError (ErrorInterface *error)
 

Detailed Description

Base class for interpreter dependent functionality each script provides.

Each Action holds a pointer to a class that implements the Script functionality for the defined Interpreter .

Definition at line 43 of file core/script.h.

Constructor & Destructor Documentation

Script::Script ( Interpreter *  interpreter,
Action *  action 
)

Constructor.

Parameters
interpreterThe Interpreter instance that was used to created this Script instance.
ActionThe Action instance this script is associated with.

Definition at line 41 of file core/script.cpp.

Script::~Script ( )
virtual

Destructor.

Definition at line 51 of file core/script.cpp.

Member Function Documentation

Action * Script::action ( ) const
slot
Returns
the Action instance associated with this Script .

Definition at line 61 of file core/script.cpp.

virtual QVariant Kross::Script::callFunction ( const QString &  name,
const QVariantList &  args = QVariantList() 
)
pure virtualslot

Call a function in the script.

Parameters
nameThe name of the function which should be called.
argsThe optional list of arguments.

Implemented in Kross::KjsScript.

virtual QVariant Kross::Script::evaluate ( const QByteArray &  code)
pure virtualslot

Evaluate some scripting code.

Parameters
codeThe scripting code to evaluate.
Returns
The return value of the evaluation.

Implemented in Kross::KjsScript.

virtual void Kross::Script::execute ( )
pure virtualslot

Execute the script.

Implemented in Kross::KjsScript.

virtual QStringList Kross::Script::functionNames ( )
pure virtualslot
Returns
the list of functionnames.

Implemented in Kross::KjsScript.

Interpreter * Script::interpreter ( ) const
slot
Returns
the Interpreter instance that was used to created this Script .

Definition at line 56 of file core/script.cpp.


The documentation for this class was generated from the following files:
  • core/script.h
  • core/script.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:49:54 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

Kross

Skip menu "Kross"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdelibs API Reference

Skip menu "kdelibs API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  • kjsembed
  •   WTF
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Nepomuk-Core
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal