VICI  0.11.815
Visual Chart Interpreter
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Public Member Functions | Static Public Attributes | List of all members
VICI::Interp::Interpreter Class Referenceabstract

The API for interpreter library. More...

#include <vici/vici.h>

Inheritance diagram for VICI::Interp::Interpreter:
VICI::stub::InterpreterStub

Public Member Functions

virtual ~Interpreter ()
 virtual destructor
 
virtual void addClient (InterpreterClient *)=0
 add a client for notifications
 
virtual void setScript (csr filename)=0
 the XML VICI script to execute
 
virtual void setArgs (VICI::ArgList args)=0
 set the program options
 
virtual void debugMode (bool mode)=0
 enable debug mode More...
 
virtual int openDisplay (NodeId node)=0
 open a Display object for reading More...
 
virtual void dataAck (NodeId node)=0
 call this after responding to InterpreterClient::dataReady() to wait for the next set of data. More...
 
virtual void setValue (csr varName, csr value)=0
 this is called when a variable has its value changed by the user More...
 
virtual void setPosn (ThreadId tid, NodeId node)=0
 call this to set the point where execution resumes More...
 
virtual void setBreak (NodeId node, bool set)=0
 call this to mark a node as a break point More...
 
virtual void setInterval (double secs)=0
 set the time interval between executing commands More...
 
virtual void saveSnapshot (csr filename)=0
 save a snapshot file More...
 
virtual void loadSnapshot (csr filename)=0
 restore a snapshot file More...
 
virtual void run ()=0
 start running the script
 
virtual void run (csr functionName)=0
 start running the script at a specified function More...
 
virtual void pause ()=0
 pause the script
 
virtual void step (ThreadId tid)=0
 
virtual void resume ()=0
 resume a paused script
 
virtual void kill ()=0
 stop the script
 
virtual int result ()=0
 get the exit code
 

Static Public Attributes

static const NodeId OutDisplay = -1
 the node id of the default output display
 
static const NodeId ErrDisplay = -2
 the node id of the default error display
 

Detailed Description

The API for interpreter library.

This is the facade for the interpreter library, libvici.

It provides an interface that lets the user control the operation of the interpreter.

Member Function Documentation

virtual void VICI::Interp::Interpreter::dataAck ( NodeId  node)
pure virtual

call this after responding to InterpreterClient::dataReady() to wait for the next set of data.

Parameters
nodethe node id of the display that is being acknowledged.

Implemented in VICI::stub::InterpreterStub.

virtual void VICI::Interp::Interpreter::debugMode ( bool  mode)
pure virtual

enable debug mode

turning this on causes events to be generated at each step of the processing.

Parameters
modeset this true to enable debugging mode

Implemented in VICI::stub::InterpreterStub.

virtual void VICI::Interp::Interpreter::loadSnapshot ( csr  filename)
pure virtual

restore a snapshot file

Parameters
filenamethe name of the file to load the state from

Implemented in VICI::stub::InterpreterStub.

virtual int VICI::Interp::Interpreter::openDisplay ( NodeId  node)
pure virtual

open a Display object for reading

the InterpreterClient::dataReady() will be called when the file descriptor has data to be read.

Parameters
nodethe display object to open
Returns
file descriptor of the display object

Implemented in VICI::stub::InterpreterStub.

virtual void VICI::Interp::Interpreter::run ( csr  functionName)
pure virtual

start running the script at a specified function

Parameters
functionNamethe function to start

Implemented in VICI::stub::InterpreterStub.

virtual void VICI::Interp::Interpreter::saveSnapshot ( csr  filename)
pure virtual

save a snapshot file

Parameters
filenamethe name of the file to save the interpreter state to

Implemented in VICI::stub::InterpreterStub.

virtual void VICI::Interp::Interpreter::setBreak ( NodeId  node,
bool  set 
)
pure virtual

call this to mark a node as a break point

Parameters
nodeThe node to break execution on when reached
setTrue to set the breakpoint and false to clear it.

Implemented in VICI::stub::InterpreterStub.

virtual void VICI::Interp::Interpreter::setInterval ( double  secs)
pure virtual

set the time interval between executing commands

Parameters
secsthe interval to wait between executing commands

Implemented in VICI::stub::InterpreterStub.

virtual void VICI::Interp::Interpreter::setPosn ( ThreadId  tid,
NodeId  node 
)
pure virtual

call this to set the point where execution resumes

Parameters
tidthe execution thread to be repositioned
nodethe place to resume execution

Implemented in VICI::stub::InterpreterStub.

virtual void VICI::Interp::Interpreter::setValue ( csr  varName,
csr  value 
)
pure virtual

this is called when a variable has its value changed by the user

Parameters
varNamethe variable being changed
valuethe new value to assign to the variable

Implemented in VICI::stub::InterpreterStub.

virtual void VICI::Interp::Interpreter::step ( ThreadId  tid)
pure virtual
Parameters
tidthe thread to execute one command from

Implemented in VICI::stub::InterpreterStub.


The documentation for this class was generated from the following file: