SmacqScheduler Class Reference

#include <SmacqScheduler.h>

Collaboration diagram for SmacqScheduler:

[legend]
List of all members.

Detailed Description

This is a scheduler for processing any number of SmacqGraph instances.


Public Member Functions

 SmacqScheduler ()
 A default graph must be specified.
void setDebug ()
 Set debug output.
bool isDebug ()
 Get debug status.
void seed_produce (SmacqGraph *)
 Cue the head(s) of the given graph to start producing data.
void seed_produce (SmacqGraphNode *startf)
 Cue the graph to start producing data.
void input (SmacqGraph *g, DtsObject din)
 Queue an object for input to the specified graph.
DtsObject get ()
 Run until an output object is ready, and return that object.
smacq_result decide (SmacqGraphNode *, DtsObject din)
 Process a single action or object.
smacq_result decideContainer (SmacqGraph *, DtsObject din)
 Process a single action or object.
bool busy_loop ()
 Run to completion.
void enqueue (SmacqGraphNode *f, DtsObject d, int outchan)
 Handle an object produced by a currently running node.
void queue_children (SmacqGraphNode_ptr, DtsObject d, int outchan)
 Handle an object produced by the specified node.
bool element (DtsObject &dout)
 Process a single action or object.
DtsObject pyelement ()
 Created for the python smacq library Process a single action or object, if output is produced, return that output.
bool done ()
 Return true if the query is done processing.
void start_threads (int numt)
 Create some threads to process the current workload.

Public Attributes

runq< SmacqGraphNode_ptr > consumeq
runq< SmacqGraphNode_ptr > produceq
runq< DtsObjectoutputq


Constructor & Destructor Documentation

SmacqScheduler::SmacqScheduler (  )  [inline]

A default graph must be specified.

Graph graph's init() method is called before anything else is done.


Member Function Documentation

bool SmacqScheduler::busy_loop (  ) 

Run to completion.

Return false iff error.

smacq_result SmacqScheduler::decide ( SmacqGraphNode g,
DtsObject  din 
)

Process a single action or object.

Return SMACQ_PASS or SMACQ_FREE.

smacq_result SmacqScheduler::decideContainer ( SmacqGraph g,
DtsObject  din 
)

Process a single action or object.

Return SMACQ_PASS or SMACQ_FREE.

bool SmacqScheduler::element ( DtsObject dout  ) 

Process a single action or object.

dout will be set to NULL or to a returned object. Returns false if we're done and true if we want to be called again.

DtsObject SmacqScheduler::get (  ) 

Run until an output object is ready, and return that object.

Return NULL if execution completes without producing object.

void SmacqScheduler::seed_produce ( SmacqGraph  ) 

Cue the head(s) of the given graph to start producing data.

Otherwise data must be provided using the input() method.

void SmacqScheduler::start_threads ( int  numt  ) 

Create some threads to process the current workload.

They will exit when there is nothing to do.


The documentation for this class was generated from the following files:
Generated on Wed Jan 23 10:01:07 2008 for SMACQ by  doxygen 1.4.7