Package uk.ac.gda.analysis.mscan
Class SwmrMalcolmProcessingReader
java.lang.Object
uk.ac.gda.analysis.mscan.SwmrMalcolmProcessingReader
Reads a datafile using a Swmr iterator extracting each frame and passing to
a list of
MalcolmSwmrProcessors.-
Constructor Summary
ConstructorsConstructorDescriptionSwmrMalcolmProcessingReader(Path filepath, int count, int dataRank, Collection<MalcolmSwmrProcessor<?>> procs, String dataPath, String detUidEntry, DatasetCreator datasetConverter) -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidStart a task asynchronously to iterate over the detector dataset as it is written and pass data to each of the configured processors.voidWait until the reading/processing task is completed
-
Constructor Details
-
SwmrMalcolmProcessingReader
public SwmrMalcolmProcessingReader(Path filepath, int count, int dataRank, Collection<MalcolmSwmrProcessor<?>> procs, String dataPath, String detUidEntry, DatasetCreator datasetConverter) - Parameters:
filepath- path for source datafilecount- total number of frames to readdataRank- rank of dataset to processprocs- processes to receive framesdataPath- path of the dataset to processdetUidEntry- path of the uid datasetdatasetConverter- applies a transformation to the dataset, ifnullthe original dataset is used as-is
-
-
Method Details
-
startAsyncReading
public void startAsyncReading()Start a task asynchronously to iterate over the detector dataset as it is written and pass data to each of the configured processors. This method may be called multiple times, the task will only be started/submitted once per lifetime of this object. -
waitUntilComplete
public void waitUntilComplete()Wait until the reading/processing task is completed -
abortReading
public void abortReading()
-