Class MXNarOutReceiverWrapper
java.lang.Object
com.metasolv.nm.processor.MXAggregator.MXNarOutReceiverWrapper
- All Implemented Interfaces:
DataProviderIfc,DataReceiverIfc,DCStreamHandler,FileDataProviderIfc,FileDataReceiverIfc
Make a DCStreamHandler-derived class for use by FlexibleTableFlush, which only uses
the writeData() methods.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancleanup()Performs any necessary cleanup desired, such as deleting files that have been processed.voidvoidAllows a DataProvider to indicate that some data is available for processingvoidAllows a FileDataProvider to indicate that some data is available for processingAllows a DataReceiver to obtain the available data in a known format.Allows a DataReceiver to obtain the currently processing .arch filegetData()Allows a DataReceiver to obtain the available data in a known format.Allows a DataReceiver to obtain the available data in a known format.Gets the object that is holding data for this DataReceiverGets the object that is retrieving data from this DataProviderAllows a FileDataReceiver to obtain the available data in a known format.Allows a FileDataReceiver to obtain the available data in a known format.Gets the object that is holding data for this FileDataReceiverGets the object that is retrieving data from this FileDataProviderReturns a DCNodePerformance object containing node performance data.Allows a DataReceiver to obtain the last processed .arch filevoidTo handle the remaining input files when there is reject of a filebooleanAllows a DataReceiver to determine whether some data is available for processingbooleanDetermines if record received is an End of file indicationbooleanAllows a FileDataReceiver to determine whether some file is available for processingbooleanDetermines if the record received is start of file indicationvoidmoveToReadyToOut(boolean initNew) Make cache file as ready to moveToOutput()voidprocessData(DCFieldContainer data) Manipulates the data provided by its DataProvidervoidprocessData(DCFieldContainer[] data) Manipulates the set of data provided by its DataProviderbooleanprocessEndOfFileData(String transactionID) Allows FileDataProvider to indicate end of file recordbooleanManipulates the data provided by its DataProviderbooleanprocessFileData(DCFieldContainer[] data) Manipulates the set of data provided by its DataProviderbooleanAllows FileDataProvider to indicate rejection of the filebooleanprocessStartOfFileData(String originalFileName) Allows FileDataProvider to indicate start of fileReads a set of DCFieldContainer objects from this DataProvider.readData()Reads a DCFieldContainer object from this DataProviderbooleanIndicates data provider to stop reading from the input file and reject itvoidremoveProcessedFile(File currArchFile) Allows a DataReceiver to remove .arch file once processed currArchFile - processed .arch filevoidsetDataProvider(DataProviderIfc provider) Sets the object from which this DataReceiver will obtain its data.voidsetDataReceiver(DataReceiverIfc receiver) Sets the object to which this DataProvider will send its data.voidsetFileDataProvider(FileDataProviderIfc provider) Sets the object from which this FileDataReceiver will obtain its data.voidsetFileDataReceiver(FileDataReceiverIfc receiver) Sets the object to which this FileDataProvider will send its data.voidsetProcessedArchFile(String file) Sets the processed .arch file absolute pathvoidsetTransactionID(String tID) voidshutdown()Performs any tasks necessary to cleanly shutdown the input and output streams of the stream handler, as appropriatevoidPerforms any tasks necessary to cleanly shutdown the input stream of the stream handlervoidPerforms any tasks necessary to cleanly shutdown the output stream of the stream handlervoidsignalBatchCompletion(String batch) Allows a DataReceiver to know that the nars under the specified batch are completed and handed over to the Data receiverbooleanAllows a DataReceiver to check if Minor Type supported for disaster recoverybooleanwriteData(DCFieldContainer datum) Stores information into a DCFieldContainer objectbooleanwriteData(DCFieldContainer[] data) Stores information into multiple DCFieldContainer objects
-
Constructor Details
-
MXNarOutReceiverWrapper
-
-
Method Details
-
writeData
Description copied from interface:DCStreamHandlerStores information into a DCFieldContainer object- Specified by:
writeDatain interfaceDCStreamHandler- Parameters:
datum- Object to put the information into- Returns:
true, if the data was successfully written to the object
-
writeData
Description copied from interface:DCStreamHandlerStores information into multiple DCFieldContainer objects- Specified by:
writeDatain interfaceDCStreamHandler- Returns:
true, if the data was successfully written to the object
-
readData
Description copied from interface:DCStreamHandlerReads a DCFieldContainer object from this DataProvider- Specified by:
readDatain interfaceDCStreamHandler
-
readBulkData
Description copied from interface:DCStreamHandlerReads a set of DCFieldContainer objects from this DataProvider.- Specified by:
readBulkDatain interfaceDCStreamHandler- Returns:
- DCFieldContainer objects, if available; null otherwise
-
getPerformanceMetrics
Description copied from interface:DCStreamHandlerReturns a DCNodePerformance object containing node performance data.- Specified by:
getPerformanceMetricsin interfaceDCStreamHandler- Returns:
- DCNodePerformance object,
-
cleanup
public boolean cleanup()Description copied from interface:DCStreamHandlerPerforms any necessary cleanup desired, such as deleting files that have been processed.- Specified by:
cleanupin interfaceDCStreamHandler
-
shutdown
public void shutdown()Description copied from interface:DCStreamHandlerPerforms any tasks necessary to cleanly shutdown the input and output streams of the stream handler, as appropriate- Specified by:
shutdownin interfaceDCStreamHandler
-
shutdownInput
public void shutdownInput()Description copied from interface:DCStreamHandlerPerforms any tasks necessary to cleanly shutdown the input stream of the stream handler- Specified by:
shutdownInputin interfaceDCStreamHandler
-
shutdownOutput
public void shutdownOutput()Description copied from interface:DCStreamHandlerPerforms any tasks necessary to cleanly shutdown the output stream of the stream handler- Specified by:
shutdownOutputin interfaceDCStreamHandler
-
dataIsAvailable
public void dataIsAvailable()Description copied from interface:DataReceiverIfcAllows a DataProvider to indicate that some data is available for processing- Specified by:
dataIsAvailablein interfaceDataReceiverIfc
-
processData
Description copied from interface:DataReceiverIfcManipulates the data provided by its DataProvider- Specified by:
processDatain interfaceDataReceiverIfc- Throws:
NodeProcessingException
-
processData
Description copied from interface:DataReceiverIfcManipulates the set of data provided by its DataProvider- Specified by:
processDatain interfaceDataReceiverIfc- Throws:
NodeProcessingException
-
setDataProvider
Description copied from interface:DataReceiverIfcSets the object from which this DataReceiver will obtain its data.- Specified by:
setDataProviderin interfaceDataReceiverIfc- Parameters:
provider- Object which has data that needs to be retrieved by this DataReceiver
-
getDataProvider
Description copied from interface:DataReceiverIfcGets the object that is holding data for this DataReceiver- Specified by:
getDataProviderin interfaceDataReceiverIfc- Returns:
- Object from which this DataReceiver is retrieving data
-
isDataAvailable
public boolean isDataAvailable()Description copied from interface:DataProviderIfcAllows a DataReceiver to determine whether some data is available for processing- Specified by:
isDataAvailablein interfaceDataProviderIfc- Returns:
true, if data is available
-
getData
Description copied from interface:DataProviderIfcAllows a DataReceiver to obtain the available data in a known format.- Specified by:
getDatain interfaceDataProviderIfc- Returns:
- DCFieldContainer object containing the data that is available for processing
-
getBulkData
Description copied from interface:DataProviderIfcAllows a DataReceiver to obtain the available data in a known format.- Specified by:
getBulkDatain interfaceDataProviderIfc- Returns:
- DCFieldContainer object array, containing the data that is for processing
-
setDataReceiver
Description copied from interface:DataProviderIfcSets the object to which this DataProvider will send its data.- Specified by:
setDataReceiverin interfaceDataProviderIfc- Parameters:
receiver- Object which will obtain data from this DataProvider
-
getDataReceiver
Description copied from interface:DataProviderIfcGets the object that is retrieving data from this DataProvider- Specified by:
getDataReceiverin interfaceDataProviderIfc- Returns:
- Object to which this DataProvider is sending data
-
moveToReadyToOut
public void moveToReadyToOut(boolean initNew) Description copied from interface:DCStreamHandlerMake cache file as ready to moveToOutput()- Specified by:
moveToReadyToOutin interfaceDCStreamHandler
-
createNewCacheFile
public void createNewCacheFile()- Specified by:
createNewCacheFilein interfaceDCStreamHandler
-
isFileDataAvailable
public boolean isFileDataAvailable()Description copied from interface:FileDataProviderIfcAllows a FileDataReceiver to determine whether some file is available for processing- Specified by:
isFileDataAvailablein interfaceFileDataProviderIfc- Returns:
true, if data is available
-
isEndOfFile
public boolean isEndOfFile()Description copied from interface:FileDataProviderIfcDetermines if record received is an End of file indication- Specified by:
isEndOfFilein interfaceFileDataProviderIfc- Returns:
true, if data is available
-
isStartOfFile
public boolean isStartOfFile()Description copied from interface:FileDataProviderIfcDetermines if the record received is start of file indication- Specified by:
isStartOfFilein interfaceFileDataProviderIfc- Returns:
-
getFileData
Description copied from interface:FileDataProviderIfcAllows a FileDataReceiver to obtain the available data in a known format.- Specified by:
getFileDatain interfaceFileDataProviderIfc- Returns:
- DCFieldContainer object containing the data that is available for processing
-
getFileBulkData
Description copied from interface:FileDataProviderIfcAllows a FileDataReceiver to obtain the available data in a known format.- Specified by:
getFileBulkDatain interfaceFileDataProviderIfc- Returns:
- DCFieldContainer object array, containing the data that is for processing
-
setFileDataReceiver
Description copied from interface:FileDataProviderIfcSets the object to which this FileDataProvider will send its data.- Specified by:
setFileDataReceiverin interfaceFileDataProviderIfc- Parameters:
receiver- Object which will obtain data from this FileDataProvider
-
getFileDataReceiver
Description copied from interface:FileDataProviderIfcGets the object that is retrieving data from this FileDataProvider- Specified by:
getFileDataReceiverin interfaceFileDataProviderIfc- Returns:
- Object to which this FileDataProvider is sending data
-
fileDataIsAvailable
public void fileDataIsAvailable()Description copied from interface:FileDataReceiverIfcAllows a FileDataProvider to indicate that some data is available for processing- Specified by:
fileDataIsAvailablein interfaceFileDataReceiverIfc
-
processStartOfFileData
Description copied from interface:FileDataReceiverIfcAllows FileDataProvider to indicate start of file- Specified by:
processStartOfFileDatain interfaceFileDataReceiverIfc- Returns:
true, if data is available- Throws:
NodeProcessingException
-
processFileData
Description copied from interface:FileDataReceiverIfcManipulates the data provided by its DataProvider- Specified by:
processFileDatain interfaceFileDataReceiverIfc- Returns:
true, if data is processed successfully- Throws:
NodeProcessingException
-
processFileData
Description copied from interface:FileDataReceiverIfcManipulates the set of data provided by its DataProvider- Specified by:
processFileDatain interfaceFileDataReceiverIfc- Returns:
true, if data is processed successfully- Throws:
NodeProcessingException
-
processEndOfFileData
Description copied from interface:FileDataReceiverIfcAllows FileDataProvider to indicate end of file record- Specified by:
processEndOfFileDatain interfaceFileDataReceiverIfc- Returns:
true, if processed successfully- Throws:
NodeProcessingException
-
processRejectFile
Description copied from interface:FileDataReceiverIfcAllows FileDataProvider to indicate rejection of the file- Specified by:
processRejectFilein interfaceFileDataReceiverIfc- Returns:
true, if processed successfully- Throws:
NodeProcessingException
-
setFileDataProvider
Description copied from interface:FileDataReceiverIfcSets the object from which this FileDataReceiver will obtain its data.- Specified by:
setFileDataProviderin interfaceFileDataReceiverIfc- Parameters:
provider- Object which has data that needs to be retrieved by this DataReceiver
-
getFileDataProvider
Description copied from interface:FileDataReceiverIfcGets the object that is holding data for this FileDataReceiver- Specified by:
getFileDataProviderin interfaceFileDataReceiverIfc- Returns:
- Object from which this DataReceiver is retrieving data
-
openInputFile
- Specified by:
openInputFilein interfaceFileDataProviderIfc- Returns:
- Throws:
Exception
-
rejectFile
Description copied from interface:FileDataProviderIfcIndicates data provider to stop reading from the input file and reject it- Specified by:
rejectFilein interfaceFileDataProviderIfc- Returns:
truefor successful rejection of input file- Throws:
Exception
-
handleRejectOfFile
public void handleRejectOfFile()Description copied from interface:FileDataProviderIfcTo handle the remaining input files when there is reject of a file- Specified by:
handleRejectOfFilein interfaceFileDataProviderIfc
-
setTransactionID
- Specified by:
setTransactionIDin interfaceFileDataReceiverIfc
-
getData
Description copied from interface:DataProviderIfcAllows a DataReceiver to obtain the available data in a known format. batch - The nars read will be grouped under the specified batch- Specified by:
getDatain interfaceDataProviderIfc- Returns:
- DCFieldContainer object containing the data that is available for processing
-
signalBatchCompletion
Description copied from interface:DataProviderIfcAllows a DataReceiver to know that the nars under the specified batch are completed and handed over to the Data receiver- Specified by:
signalBatchCompletionin interfaceDataProviderIfc
-
removeProcessedFile
Description copied from interface:DataProviderIfcAllows a DataReceiver to remove .arch file once processed currArchFile - processed .arch file- Specified by:
removeProcessedFilein interfaceDataProviderIfc
-
getCurrArchFile
Description copied from interface:DataProviderIfcAllows a DataReceiver to obtain the currently processing .arch file- Specified by:
getCurrArchFilein interfaceDataProviderIfc- Returns:
- currently processing .arch file
-
getProcessedArchFile
Description copied from interface:DataProviderIfcAllows a DataReceiver to obtain the last processed .arch file- Specified by:
getProcessedArchFilein interfaceDataProviderIfc- Returns:
- currently processing .arch file absolute path
-
setProcessedArchFile
Description copied from interface:DataProviderIfcSets the processed .arch file absolute path- Specified by:
setProcessedArchFilein interfaceDataProviderIfc- Parameters:
file- absolute path of processed .arch file
-
validOIMinorType
public boolean validOIMinorType()Description copied from interface:DataProviderIfcAllows a DataReceiver to check if Minor Type supported for disaster recovery- Specified by:
validOIMinorTypein interfaceDataProviderIfc- Returns:
- true if valid
-