GemaLuaCoreLib
The GeMA Lua Core library
Public Member Functions | Static Private Member Functions | Private Attributes | List of all members
GmLuaCellTask Class Reference

A task function object responsible for calling a Lua function that gets as parameters an iterator for the given cell data set plus any extra parameters common to all tasks. More...

#include <gmLuaTask.h>

Collaboration diagram for GmLuaCellTask:
Collaboration graph
[legend]

Public Member Functions

 GmLuaCellTask (const QString &fname, const QVariantList &extraPars, const GmLogCategory &logger)
 Constructor. More...
 
GmThreadTaskResult operator() (GmCellTaskDataSet *dataSet, const GmThread *thread)
 The function called in each thread to process cells in the given data set.
 

Static Private Member Functions

static int iteratorClosure (lua_State *L)
 The iterator object function that gets called in the expression 'for cell in cellTask() do'. Returns the iterator function plus the dataSet that will be sent as a parameter to the iterator function.
 
static int iteratorFunction (lua_State *L)
 The iterator function called to return cell objects.
 

Private Attributes

const QString_fname
 The name of the function to be called.
 
const QVariantList & _extraPars
 The set of extra parameters, common to all tasks.
 
const GmLogCategory_logger
 A logger for error messages.
 

Detailed Description

A task function object responsible for calling a Lua function that gets as parameters an iterator for the given cell data set plus any extra parameters common to all tasks.

Constructor & Destructor Documentation

◆ GmLuaCellTask()

GmLuaCellTask::GmLuaCellTask ( const QString fname,
const QVariantList &  extraPars,
const GmLogCategory logger 
)

Constructor.

Parameters
fnameThe name of the function to be called
extraParsA list with the set of extra parameters, global to all tasks. Each list entry is a variant without any Lua references.
loggerA logger that can be used to report errors.

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