| Qore DataProvider Module Reference 3.2.2

Loading...
Searching...
No Matches
DataProviderPipelineFactory.qc.dox.h
1// -*- mode: c++; indent-tabs-mode: nil -*-
3
24
25// assume local scope for variables, do not use "$" signs
26// require type definitions everywhere
28// enable all warnings
29// allow weak references
30
32 namespace DataProvider {
34 public struct PipelineFactoryInfo {
36 *hash<auto> opts;
37
39 int num_queues;
40
42 bool bulk;
43};
44
46hashdecl PipelineQueueInfo {
48 int id;
49
51 list<auto> elems();
52
54 int size;
55};
56
58
61 class DataProviderPipelineFactory {
62
63 public:
64
65
66 protected:
68 *hash<PipelineOptionInfo> opts;
69
71 hash<string, hash<PipelineQueueInfo>> pmap;
72
74 bool do_bulk = True;
75
76 public:
77
79
83 constructor(*hash<PipelineOptionInfo> opts);
84
85
87
89 hash<PipelineFactoryInfo> getInfo();
90
91
93
95 DataProviderPipeline create(*hash<PipelineOptionInfo> opts);
96
97
99
102 append(AbstractDataProcessor processor);
103
104
106
115 append(int id, AbstractDataProcessor processor);
116
117
119
129 int appendQueue(int id);
130
131
133 protected:
134 checkUpdateQueue(softstring id);
135 public:
136
137
139 protected:
140 processQueue(DataProviderPipeline pipe, int id, hash<PipelineQueueInfo> queue);
141 public:
142
143};
144};
DataProvider::AbstractDataProcessor
Defines an abstract class for accepting data and outputting optionally transformed or filtered data.
Definition AbstractDataProcessor.qc.dox.h:33
DataProvider::DataProviderPipelineFactory
A factory class for creating DataProviderPipeline objects.
Definition DataProviderPipelineFactory.qc.dox.h:61
DataProvider::DataProviderPipelineFactory::checkUpdateQueue
checkUpdateQueue(softstring id)
Checks if the given queue exists.
DataProvider::DataProviderPipelineFactory::create
DataProviderPipeline create(*hash< PipelineOptionInfo > opts)
Creates a new DataProviderPipeline object.
DataProvider::DataProviderPipelineFactory::processQueue
processQueue(DataProviderPipeline pipe, int id, hash< PipelineQueueInfo > queue)
Creates a queue in a pipeline.
DataProvider::DataProviderPipelineFactory::constructor
constructor(*hash< PipelineOptionInfo > opts)
Creates the object with the given options.
DataProvider::DataProviderPipelineFactory::appendQueue
int appendQueue(int id)
Appends a new queue to an existing pipeline and returns the new queue ID.
DataProvider::DataProviderPipelineFactory::getInfo
hash< PipelineFactoryInfo > getInfo()
Returns pipeline factory info.
DataProvider::DataProviderPipelineFactory::do_bulk
bool do_bulk
Bulk flag.
Definition DataProviderPipelineFactory.qc.dox.h:74
DataProvider::DataProviderPipelineFactory::append
append(AbstractDataProcessor processor)
Appends a data processor to the default pipeline.
DataProvider::DataProviderPipelineFactory::append
append(int id, AbstractDataProcessor processor)
Appends a data processor to a pipeline.
DataProvider::DataProviderPipelineFactory::pmap
hash< string, hash< PipelineQueueInfo > > pmap
Hash of queues keyed by queue ID.
Definition DataProviderPipelineFactory.qc.dox.h:71
DataProvider::DataProviderPipelineFactory::opts
*hash< PipelineOptionInfo > opts
Options for the pipelines.
Definition DataProviderPipelineFactory.qc.dox.h:68
DataProvider::DataProviderPipeline
Defines a class for passing data through record processors.
Definition DataProviderPipeline.qc.dox.h:207
DataProvider
Qore AbstractDataField class definition.
Definition AbstractDataField.qc.dox.h:27
DataProvider::PipelineQueueInfo
hashdecl PipelineQueueInfo
Internal struct for pipeline queue info.
Definition DataProviderPipelineFactory.qc.dox.h:46
DataProvider::elems
list< auto > elems()
Queue elements; either AbstractDataProcessor objects or a list of PipelineQueueInfo hashes.
DataProvider::size
int size
Maximum queue size.
Definition DataProviderPipelineFactory.qc.dox.h:54
DataProvider::PipelineFactoryInfo
Pipeline factory info.
Definition DataProviderPipelineFactory.qc.dox.h:34
DataProvider::PipelineFactoryInfo::opts
*hash< auto > opts
Options for new pipelines.
Definition DataProviderPipelineFactory.qc.dox.h:36
DataProvider::PipelineFactoryInfo::num_queues
int num_queues
Number of pipeline queues.
Definition DataProviderPipelineFactory.qc.dox.h:39
DataProvider::PipelineFactoryInfo::bulk
bool bulk
Flag that indicates if the pipelines to be created are capable of bulk record processing.
Definition DataProviderPipelineFactory.qc.dox.h:42